diff options
author | happysalada <raphael@megzari.com> | 2023-06-15 12:54:03 -0400 |
---|---|---|
committer | Yt <happysalada@tuta.io> | 2023-06-15 14:18:22 -0400 |
commit | b55b4151987280cfb6936522a56854183387b0d2 (patch) | |
tree | 94339112e1bd9f09be1e9e45153a8e1d5832e27e /pkgs/servers/web-apps | |
parent | 147635ed43d836f93f64dcb1b51a5fb2362a697a (diff) |
lemmy: fix update script (hash + running dir)
Diffstat (limited to 'pkgs/servers/web-apps')
-rwxr-xr-x | pkgs/servers/web-apps/lemmy/update.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pkgs/servers/web-apps/lemmy/update.sh b/pkgs/servers/web-apps/lemmy/update.sh index 6b18221e2672a..8de7a8640d8fe 100755 --- a/pkgs/servers/web-apps/lemmy/update.sh +++ b/pkgs/servers/web-apps/lemmy/update.sh @@ -24,9 +24,9 @@ if ("$latest_version" === "$current_version") { const package_json = $(curl -qf $source/package.json) echo $package_json > $directory/package.json - const server_tarball_meta = $(nix-prefetch-github $owner $server_repo --rev $latest_rev) + const server_tarball_meta = $(nix-prefetch-github $owner $server_repo --rev $latest_rev --fetch-submodules) const server_tarball_hash = "sha256-$(echo $server_tarball_meta | jq -r '.sha256')" - const ui_tarball_meta = $(nix-prefetch-github $owner $ui_repo --rev $latest_rev) + const ui_tarball_meta = $(nix-prefetch-github $owner $ui_repo --rev $latest_rev --fetch-submodules) const ui_tarball_hash = "sha256-$(echo $ui_tarball_meta | jq -r '.sha256')" jq ".version = \"$latest_version\" | \ @@ -35,12 +35,12 @@ if ("$latest_version" === "$current_version") { .\"serverCargoSha256\" = \"\" | \ .\"uiYarnDepsSha256\" = \"\"" $directory/pin.json | sponge $directory/pin.json - const new_cargo_sha256 = $(nix-build -A lemmy-server 2>&1 | \ + const new_cargo_sha256 = $(nix-build $directory/../../../.. -A lemmy-server 2>&1 | \ tail -n 2 | \ head -n 1 | \ sd '\s+got:\s+' '') - const new_offline_cache_sha256 = $(nix-build -A lemmy-ui 2>&1 | \ + const new_offline_cache_sha256 = $(nix-build $directory/../../../.. -A lemmy-ui 2>&1 | \ tail -n 2 | \ head -n 1 | \ sd '\s+got:\s+' '') |