nixos/home/scripts/default.nix

20 lines
621 B
Nix

{ pkgs, ... }:
{
home = {
packages = [
(pkgs.writeShellScriptBin "git-sync-all" (builtins.readFile ./shell/git-sync-all.sh))
(pkgs.writeShellScriptBin "rsync-local-config" (builtins.readFile ./shell/rsync-local-config.sh))
(pkgs.writeShellScriptBin "xdg-query-program" (builtins.readFile ./shell/xdg-query-program.sh))
];
shellAliases =
let
sync = "sudo systemctl start nixos-upgrade.service && git-sync-all";
in
{
gsa = "git-sync-all";
sync-and-shutdown = sync + " && shutdown now";
sync-and-reboot = sync + " && reboot";
};
};
}