Closed AlekSi closed 5 years ago
Travis CI failed for an unrelated reason, PTAL.
Excited to see this get merged.
uname_os() {
os=$(uname -s | tr '[:upper:]' '[:lower:]')
case "$os" in
msys_nt*) os="windows" ;;
mingw*) os="windows" ;;
esac
echo "$os"
}
You'll probably want something like this to be more friendly with git-bash.exe
, which is the more common shell installation most people use (not the best, just most common)
Note: I have basically no practical knowledge of shell scripting, so I'm sure there's a more optimized way to write that - Functionally was all I was referring to.
+1 also just ran into this issue for mingw*
as well.
Please add this case and merge! :)
+1 for @syntaqx 's solution cc @client9 -- thanks for taking the time to fix this! (confirmed the fix works on win10 + git bash)
Updated PR with @syntaqx's solution.
@client9 Please find a minute to click merge button – it is a small change, it is tested by us, and fixes a real problem we are having.
Thank you!
@AlekSi and friends... I'd be happy to give you commit rights if you want! Windows is something I'm never going to be able to support!
@client9 If you need help with Windows support I'm happy to help. I work on Windows full time and fix this kind of stuff constantly :P
and it was so 💥
thanks @syntaqx
Same here, my company is now relying on this package so have a vested interest in keeping it working smoothly on all platforms :) Would be happy to help maintain. Thanks again for the fast reply and for merging! 💯
I'd love to know how you all are using it. @syntaqx @DABH !
In my case we have a cross-platform installer script for a software package, which users can curl ... | sh
to download and install on their machines. So one can imagine how many of these scripts are useful :)
My first use case was when I was using https://goreleaser.com/ to automate binary releases for a Go project. They had the project as a dependency.
Now I use it for pretty much any scripting suite I deliver. I work in operations/devops/infrastructure so scripts and their compatibility is life.
@syntaqx same here. @DABH and I discovered this via godownloader as well. Pretty nice suite. :)
Closes #13.