plausible: simplify update script
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
runCommand,
|
||||
nixosTests,
|
||||
npm-lockfile-fix,
|
||||
nix-update-script,
|
||||
brotli,
|
||||
tailwindcss_3,
|
||||
esbuild,
|
||||
@@ -91,7 +92,9 @@ let
|
||||
};
|
||||
};
|
||||
|
||||
patchedMixFodDeps = runCommand mixFodDeps.name { } ''
|
||||
patchedMixFodDeps = runCommand mixFodDeps.name {
|
||||
inherit (mixFodDeps) hash;
|
||||
} ''
|
||||
mkdir $out
|
||||
cp -r --no-preserve=mode ${mixFodDeps}/. $out
|
||||
|
||||
@@ -125,8 +128,21 @@ beamPackages.mixRelease rec {
|
||||
tests = {
|
||||
inherit (nixosTests) plausible;
|
||||
};
|
||||
updateScript = ./update.sh;
|
||||
inherit assets tracker;
|
||||
updateScript = nix-update-script {
|
||||
extraArgs = [
|
||||
"-s"
|
||||
"tracker"
|
||||
"-s"
|
||||
"assets"
|
||||
"-s"
|
||||
"mjmlNif"
|
||||
];
|
||||
};
|
||||
inherit
|
||||
assets
|
||||
tracker
|
||||
mjmlNif
|
||||
;
|
||||
};
|
||||
|
||||
env = {
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i bash -p nix-update jq elixir npm-lockfile-fix nixfmt-rfc-style
|
||||
|
||||
set -euxo pipefail
|
||||
|
||||
nix-update plausible
|
||||
|
||||
version="$(nix-instantiate -A plausible.version --eval --json | jq -r)"
|
||||
source_url="$(nix-instantiate -A plausible.src.url --eval --json | jq -r)"
|
||||
|
||||
nix-update --url "$source_url" --version "$version" plausible.tracker
|
||||
nix-update --url "$source_url" --version "$version" plausible.assets
|
||||
|
||||
|
||||
Reference in New Issue
Block a user