Skip to content

Commit

Permalink
Fix Windows install-stack (hopefully)
Browse files Browse the repository at this point in the history
  • Loading branch information
Yvee1 committed Dec 17, 2023
1 parent 98248a8 commit c8fa7c3
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions .github/scripts/install-stack.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,20 @@ else
ARCH="osx"
fi
URL="https://www.stackage.org/stack/$ARCH-x86_64"
curl --location "$URL" > stack.tar.gz
gunzip stack.tar.gz
tar -x -f stack.tar --strip-components 1
mkdir -p "$HOME/.local/bin"
if [ "$RUNNER_OS" = "Windows" ]
then
if [ "$RUNNER_OS" = "Windows" ] then
curl --location "$URL" > stack.zip
unzip stack.zip
mkdir "$HOME/stack"
mv stack.exe "$HOME/stack"
export PATH=$PATH:"$HOME/stack"
else
curl --location "$URL" > stack.tar.gz
gunzip stack.tar.gz
tar -x -f stack.tar --strip-components 1
mkdir -p "$HOME/.local/bin"
mv stack "$HOME/.local/bin/"
rm stack.tar
fi
rm stack.tar
fi

stack --version

0 comments on commit c8fa7c3

Please sign in to comment.