diff --git a/.gitignore b/.gitignore index 64dfc3b2..317665b2 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,6 @@ # Ignore nixos build outputs result* .direnv/ + +# deploy script +.deploy-summary diff --git a/justfile b/justfile index d844a672..dc028845 100644 --- a/justfile +++ b/justfile @@ -31,11 +31,25 @@ deploy host *args: set -euo pipefail before=$(ssh {{ host }} 'readlink /run/current-system') just builder switch --target-host {{ host }} --use-substitutes {{ args }} - ssh {{ host }} lix diff "$before" + + if [[ -n "${DEPLOY_SUMMARY:-}" ]]; then + { + echo "===== {{ host }} =====" + ssh {{ host }} lix diff "$before" + echo + } >> "$DEPLOY_SUMMARY" + else + ssh {{ host }} lix diff "$before" + fi [group('rebuild')] [no-exit-message] deploy-all: + #!/usr/bin/env bash + set -euo pipefail + export DEPLOY_SUMMARY=".deploy-summary" + : > "$DEPLOY_SUMMARY" + just deploy minerva just deploy athena just deploy aphrodite @@ -43,6 +57,11 @@ deploy-all: just deploy hephaestus just deploy isis + echo + echo "===== DEPLOYMENT SUMMARY =====" + cat "$DEPLOY_SUMMARY" + @rm "$DEPLOY_SUMMARY" + # rebuild the boot [group('rebuild')] [no-exit-message]