1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-12-25 03:09:47 +01:00
home-manager/tests/modules/programs/pet/snippets.nix
Tamás Hetesi 1e7e8ac75d
pet: Add support for tags in snippets (#1883)
Add missing `tag` option for elements of `programs.pet.snippets`.
2021-04-20 16:16:27 -04:00

29 lines
621 B
Nix

{ config, lib, pkgs, ... }:
with lib;
{
config = {
programs.pet = {
enable = true;
selectcmdPackage = pkgs.writeScriptBin "pet-cmd" "" // {
outPath = "@pet-cmd@";
};
snippets = [{
description = "git: search full history for regex";
command = "git log -p -G <regex>";
tag = [ "git" "regex" ];
}];
};
nixpkgs.overlays = [
(self: super: {
pet = pkgs.writeScriptBin "pet" "" // { outPath = "@pet@"; };
})
];
nmt.script = ''
assertFileContent home-files/.config/pet/snippet.toml ${./snippet.toml}
'';
};
}