fork/home-manager
git clone https://git.julia.blue/fork/home-manager
b7eb400d
master
1{ pkgs , ...} : 2 3{ 4programs . pistol = { 5enable = true ; 6associations = [ 7{ 8mime = "application/json" ; 9command = "bat %pistol-filename%" ; 10} 11{ 12mime = "application/*" ; 13command = "hexyl %pistol-filename%" ; 14} 15{ 16fpath = ".*.md$" ; 17command = 18"sh: bat --paging=never --color=always %pistol-filename% | head -8" ; 19} 20]; 21}; 22 23test . stubs . pistol = { }; 24 25nmt . script = let 26expected = builtins . toFile "config-expected" '' 27application/json bat %pistol-filename% 28application/* hexyl %pistol-filename% 29fpath .*.md$ sh: bat --paging=never --color=always %pistol-filename% | head -8'' ; 30path = if pkgs . stdenv . hostPlatform . isDarwin then 31"home-files/Library/Application Support/pistol/pistol.conf" 32else 33"home-files/.config/pistol/pistol.conf" ; 34in '' 35assertFileExists ' ${ path } ' 36assertFileContent ' ${ path } ' ' ${ expected } ' 37'' ; 38}