diff --git a/action.yml b/action.yml index 2d2a1b1..046a7d8 100644 --- a/action.yml +++ b/action.yml @@ -66,7 +66,11 @@ runs: else depot="~/.julia" fi - depot="${depot/#\~/$HOME}" # Expand tilde which cannot be used in BASH checks (i.e. `[ -d "~/.julia" ]` fails) + if [[ "$OSTYPE" == "msys" || "$OSTYPE" == "cygwin" ]]; then + depot="${depot/#\~/$USERPROFILE}" # Windows paths + else + depot="${depot/#\~/$HOME}" # Unix-like paths + fi echo "depot=$depot" | tee -a "$GITHUB_OUTPUT" cache_paths=()