mirror of
https://github.com/kennyp/asdf-golang.git
synced 2024-10-06 04:32:07 +08:00
Incorporate changes from @vifino to support armv{6,7}l/Alpine Linux.
Closes #3
This commit is contained in:
parent
01994416c6
commit
ceb54998d2
@ -19,8 +19,8 @@ Feel free to create an issue or pull request if you find a bug.
|
||||
|
||||
## Issues
|
||||
|
||||
* Assumes Linux or Mac
|
||||
* Assumes x86_64 or 386
|
||||
* Assumes Linux, FreeBSD, or Mac
|
||||
* Assumes x86_64, i386, i686, armv6l or armv7l
|
||||
|
||||
## License
|
||||
MIT License
|
||||
|
@ -23,7 +23,12 @@ get_arch () {
|
||||
|
||||
case "$(uname -m)" in
|
||||
x86_64|amd64) arch="amd64"; ;;
|
||||
*) arch="386"; ;;
|
||||
i686|i386) arch="386"; ;;
|
||||
armv6l|armv7l) arch="armv6l"; ;;
|
||||
*)
|
||||
echo "Arch '$(uname -m)' not supported!" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
echo -n $arch
|
||||
|
@ -52,7 +52,7 @@ echo ${VERSIONS[@]} \
|
||||
| tr ' ' '\n' \
|
||||
| grep '.tar.gz' \
|
||||
| grep '\(linux\|darwin\|freebsd\)' \
|
||||
| grep '\-\(amd64\|386\)\.' \
|
||||
| grep '\-\(amd64\|386\|armv6l\|armv7l\)\.' \
|
||||
| sed -e 's/^go\([^.]*\).\([^.]*\).\([^.]*\).*/\1.\2.\3/' \
|
||||
| sed -e 's/.\(linux\|darwin\|freebsd\|src\).*$//' \
|
||||
| uniq \
|
||||
|
Loading…
Reference in New Issue
Block a user