Skip to content

Commit

Permalink
~
Browse files Browse the repository at this point in the history
  • Loading branch information
oluceps committed Feb 22, 2024
1 parent 318fbd3 commit bd7218e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions hosts/lib.nix
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@ in
genCredPath = config: key: (key + ":" + config.age.secrets.${key}.path);

genNtfyMsgScriptPath = header: level: body:
toString (pkgs.lib.getExe (pkgs.nuenv.writeScriptBin
pkgs.lib.getExe (pkgs.nuenv.writeScriptBin
{
name = "post-ntfy-msg";
script = "http post --password $in --headers [${header}] https://ntfy.nyaw.xyz/${level} ${body}";
}));
});

base =
let inherit (inputs.nixpkgs) lib;
Expand Down
4 changes: 2 additions & 2 deletions modules/snapy.nix
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ in
User = "root";
ExecStart =
let btrfs = lib.getExe' pkgs.btrfs-progs "btrfs"; in
toString (pkgs.lib.getExe (pkgs.nuenv.writeScriptBin
pkgs.lib.getExe (pkgs.nuenv.writeScriptBin
{
name = "snapy";
script = ''
Expand All @@ -72,7 +72,7 @@ in
# clean outdated
ls ${s.source}/.snapshots | filter { |i| ((date now) - ($i.name | path basename | into datetime --format $date_format)) > ${s.keep} } | each { |d| ${btrfs} sub del $d.name }
'';
}));
});
};
};
})
Expand Down

0 comments on commit bd7218e

Please sign in to comment.