Created
October 4, 2015 19:58
-
-
Save lulu-berlin/b4ec77d2c051de5da222 to your computer and use it in GitHub Desktop.
A shell script for Cygwin to download and run the install program
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [[ $(getconf LONG_BIT) == "64" ]]; then | |
setup_file="setup-x86_64.exe" | |
else | |
setup_file="setup-x86.exe" | |
fi | |
wget -N "https://cygwin.com/$setup_file" -P /usr/local/bin | |
if [[ $? != 0 ]]; then | |
echo "Cannot download Cygwin setup. Aborting." | |
exit $? | |
else | |
chmod +x "/usr/local/bin/$setup_file" | |
${setup_file} | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment