diff --git a/modules/cli/fish.nix b/modules/cli/fish.nix index 908bb66..19e1468 100644 --- a/modules/cli/fish.nix +++ b/modules/cli/fish.nix @@ -1,4 +1,4 @@ -{ userConfig, hostName, ... }: +{ userConfig, ... }: { programs.fish = { @@ -76,6 +76,37 @@ "pandoc $argv -t html |wl-copy -t text/html"; }; + update_files = { + body = + # fish + '' + echo "=== System packages updates ===" + pushd /etc/nixos + + git add -A + git commit -m 'chore: state before pulling' + + if git pull + reload_system + end + + popd + + echo "=== User packages update ===" + pushd $HOME/.config/home-manager + + git add -A + git commit -m 'chore: state before pulling' + + if git pull + reload_dotfiles + end + + popd + ''; + + }; + update = { body = if userConfig.isNixOS then