summary refs log tree commit diff
path: root/nix-update.sh
diff options
context:
space:
mode:
authorRory& <myrainbowdash949@gmail.com>2024-02-19 10:09:50 +0000
committerGitHub <noreply@github.com>2024-02-19 21:09:50 +1100
commit29df169c81d963742cc973a8835a7c1a126d7220 (patch)
tree7db8092c20e187ff812f8b9f71b28c5c25641d56 /nix-update.sh
parentFix application icons (#1110) (diff)
downloadserver-29df169c81d963742cc973a8835a7c1a126d7220.tar.xz
Add nix flake to repo (#1111)
Diffstat (limited to 'nix-update.sh')
-rwxr-xr-xnix-update.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/nix-update.sh b/nix-update.sh
new file mode 100755
index 00000000..4413e6e0
--- /dev/null
+++ b/nix-update.sh
@@ -0,0 +1,10 @@
+#!/usr/bin/env nix-shell
+#!nix-shell -i "bash -x" -p bash prefetch-npm-deps jq git nix-output-monitor
+nix flake update
+DEPS_HASH=`prefetch-npm-deps package-lock.json`
+TMPFILE=$(mktemp)
+jq '.npm_deps_hash = "'$DEPS_HASH'"' hashes.json > $TMPFILE
+mv -- "$TMPFILE" hashes.json
+
+nom build .# || exit $?
+git add hashes.json flake.lock flake.nix
\ No newline at end of file