vencord: fix paths in update script
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
This commit is contained in:
parent
f979844051
commit
df9f79bbea
1 changed files with 6 additions and 6 deletions
|
@ -1,7 +1,9 @@
|
|||
#!/usr/bin/env nix-shell
|
||||
#! nix-shell -I nixpkgs=../../.. -i bash -p curl jq common-updater-scripts prefetch-npm-deps nodejs
|
||||
#! nix-shell -i bash -p curl jq common-updater-scripts prefetch-npm-deps nodejs
|
||||
set -eou pipefail
|
||||
|
||||
pkgDir="$(dirname "$(readlink -f "$0")")"
|
||||
|
||||
tempDir=$(mktemp -d)
|
||||
|
||||
ghTags=$(curl ${GITHUB_TOKEN:+" -u \":$GITHUB_TOKEN\""} "https://api.github.com/repos/Vendicated/Vencord/tags")
|
||||
|
@ -15,10 +17,8 @@ npm install --legacy-peer-deps -f
|
|||
npmDepsHash=$(prefetch-npm-deps ./package-lock.json)
|
||||
popd
|
||||
|
||||
pushd ../../..
|
||||
update-source-version vencord "${latestTag#v}"
|
||||
popd
|
||||
|
||||
sed -E 's#\bgitHash = ".*?"#gitHash = "'"${gitHash:0:7}"'"#' -i default.nix
|
||||
sed -E 's#\bnpmDepsHash = ".*?"#npmDepsHash = "'"$npmDepsHash"'"#' -i default.nix
|
||||
cp "$tempDir/package-lock.json" package-lock.json
|
||||
sed -E 's#\bgitHash = ".*?"#gitHash = "'"${gitHash:0:7}"'"#' -i "$pkgDir/default.nix"
|
||||
sed -E 's#\bnpmDepsHash = ".*?"#npmDepsHash = "'"$npmDepsHash"'"#' -i "$pkgDir/default.nix"
|
||||
cp "$tempDir/package-lock.json" "$pkgDir/package-lock.json"
|
||||
|
|
Loading…
Reference in a new issue