From a0d2253f0bd5961a7f14984967f9b545b23e3d5f Mon Sep 17 00:00:00 2001 From: Philip Taron Date: Tue, 14 May 2024 11:23:45 -0700 Subject: [PATCH] flake.nix: update during the update script --- default.nix | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/default.nix b/default.nix index d863128..3b3fbad 100644 --- a/default.nix +++ b/default.nix @@ -86,6 +86,23 @@ let autoPrUpdate = let updateScripts = { + flake = pkgs.writeShellApplication { + name = "update-flake"; + runtimeInputs = with pkgs; [ + git + nix + ]; + text = '' + echo "
flake.nix changes" + # Needed because GitHub's rendering of the first body line breaks down otherwise + echo "" + echo '```' + cd "$1" + nix flake update 2>&1 + echo '```' + echo "
" + ''; + }; npins = pkgs.writeShellApplication { name = "update-npins"; runtimeInputs = with pkgs; [ npins ];