summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSam Tay <samctay@pm.me>2022-08-21 10:02:03 -0700
committerSam Tay <samctay@pm.me>2022-08-21 10:02:03 -0700
commita5c702e7eaabc4327b4f6b539d24bc37a387b792 (patch)
treec4bc259caa6ce8e970389cdc5cec5dc32e1a74a5
parentcc64aa64464d8dd0cc637d57bc86176e2066faeb (diff)
Fix install script
-rw-r--r--ci/before_deploy.ps12
-rwxr-xr-xdocs/install.sh8
2 files changed, 7 insertions, 3 deletions
diff --git a/ci/before_deploy.ps1 b/ci/before_deploy.ps1
index 5bc9388..583307c 100644
--- a/ci/before_deploy.ps1
+++ b/ci/before_deploy.ps1
@@ -8,7 +8,7 @@ Set-Location $env:TEMP
New-Item -Type Directory -Name $STAGE
Set-Location $STAGE
-$ZIP = "$SRC_DIR\$($env:CRATE_NAME)-$($env:APPVEYOR_REPO_TAG_NAME)-$($env:TARGET).zip"
+$ZIP = "$SRC_DIR\$($env:CRATE_NAME)-$($env:TARGET).zip"
Copy-Item "$SRC_DIR\target\$($env:TARGET)\release\$($env:CRATE_NAME).exe" '.\'
diff --git a/docs/install.sh b/docs/install.sh
index 1ef1dca..1172e4b 100755
--- a/docs/install.sh
+++ b/docs/install.sh
@@ -99,10 +99,14 @@ if [ -z ${dest-} ]; then
fi
if [ -z ${tag-} ]; then
- tag=$(curl -s "$releases/latest" | cut -d'"' -f2 | rev | cut -d'/' -f1 | rev)
+ tag=$(
+ curl --silent "https://api.github.com/repos/samtay/so/releases/latest" |
+ grep '"tag_name":' |
+ sed -E 's/.*"([^"]+)".*/\1/'
+ )
fi
-archive="$releases/download/$tag/$crate-$tag-$target.tar.gz"
+archive="$releases/download/$tag/$crate-$target.tar.gz"
say_err "Repository: $url"
say_err "Crate: $crate"