File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -24,11 +24,27 @@ determineDistro()
2424
2525determineDistro
2626
27+ case " $( uname -m) " in
28+ " x86_64" | " amd64" )
29+ $ARCH =" amd64"
30+ ;;
31+ " aarch64" | " arm64" )
32+ $ARCH =" arm64"
33+ ;;
34+ " i386" | " i686" )
35+ $ARCH =" x86"
36+ ;;
37+ * )
38+ echo " Unsupported architecture."
39+ exit 1
40+ ;;
41+ esac
42+
2743if [ -z " $SOURCE " ]; then
2844 if [ " $DISTRO " = " alpine" ]; then
29- SOURCE=" https://github.com/draconware-dev/LineCount/releases/download/__VERSION__/loc-__VERSION__-linux-alpine-amd64 .tar.xz"
45+ SOURCE=" https://github.com/draconware-dev/LineCount/releases/download/__VERSION__/loc-__VERSION__-linux-alpine-$ARCH .tar.xz"
3046 else
31- SOURCE=" https://github.com/draconware-dev/LineCount/releases/download/__VERSION__/loc-__VERSION__-linux-amd64 .tar.xz"
47+ SOURCE=" https://github.com/draconware-dev/LineCount/releases/download/__VERSION__/loc-__VERSION__-linux-$ARCH .tar.xz"
3248 fi
3349fi
3450
You can’t perform that action at this time.
0 commit comments