ArchiSteamFarm: make update scripts indepent from where they are run, cleanups

This commit is contained in:
Sandro Jäckel 2022-10-15 01:50:48 +02:00 committed by Sandro Jäckel
parent 0f386859f5
commit b38799bbb4
No known key found for this signature in database
GPG key ID: B1763F8651144063
2 changed files with 3 additions and 4 deletions

View file

@ -15,15 +15,13 @@ if [[ "$new_version" == "$old_version" ]]; then
fi
fi
asf_path=$(pwd)
asf_path=$PWD
cd ../../../..
nixpkgs_path=$(pwd)
if [[ "${1:-}" != "--deps-only" ]]; then
update-source-version ArchiSteamFarm "$new_version"
fi
$(nix-build -A ArchiSteamFarm.fetch-deps --no-out-link) "$deps_file"
cd "$asf_path"
./web-ui/update.sh
exec "$asf_path/web-ui/update.sh"

View file

@ -2,6 +2,7 @@
#! nix-shell -I nixpkgs=../../../../.. -i bash -p nodePackages.node2nix gnused jq curl
set -eoux pipefail
cd "$(dirname "$0")"
pushd ../../../../..
version=$(nix-instantiate --strict --eval -A ArchiSteamFarm.version | jq -r)
popd