Skip to content

Commit d32ae0b

Browse files
committed
fix: Golang install: use "amd64" for "x86_64"
1 parent 1d4211c commit d32ae0b

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

scripts/bundling.bash

+4-2
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,13 @@ function _rename_built_xpi() {
8181
function bundle_production_webextension() {
8282
local version && version=$(browsh_version)
8383
local base='https://github.com/browsh-org/browsh/releases/download'
84-
local release_url="$base/v$version/browsh-$version-an.fx.xpi"
84+
local release_url="$base/v$version/browsh-$version.xpi"
8585
echo "Downloading webextension from: $release_url"
86-
local size && size=$(wc -c <"$XPI_PATH")
8786
curl -L -o "$XPI_PATH" "$release_url"
87+
local size && size=$(wc -c <"$XPI_PATH")
8888
if [ "$size" -lt 500 ]; then
89+
echo "XPI size seems too small: $size"
8990
_panic "Problem downloading latest webextension XPI"
9091
fi
92+
cp -a "$XPI_PATH" "$(versioned_xpi_file)"
9193
}

scripts/misc.bash

+4-2
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,12 @@ function install_golang() {
5353
[ "$GOROOT" = "" ] && _panic "GOROOT not set"
5454
GOARCH=$(uname -m)
5555
[[ $GOARCH == aarch64 ]] && GOARCH=arm64
56-
echo "Installing Golang v$version... to $GOROOT"
56+
[[ $GOARCH == x86_64 ]] && GOARCH=amd64
57+
url=https://dl.google.com/go/go"$version".linux-"$GOARCH".tar.gz
58+
echo "Installing Golang ($url)... to $GOROOT"
5759
curl -L \
5860
-o go.tar.gz \
59-
https://dl.google.com/go/go"$version".linux-"$GOARCH".tar.gz
61+
"$url"
6062
mkdir -p "$GOPATH"/bin
6163
mkdir -p "$GOROOT"
6264
tar -C "$GOROOT/.." -xzf go.tar.gz

0 commit comments

Comments
 (0)