fork/home-manager
git clone https://git.julia.blue/fork/home-manager
44635279
master
1{ config , lib , pkgs , ...} : 2 3with lib ; 4 5{ 6config = { 7programs . bat = { 8enable = true ; 9 10config = { 11theme = "TwoDark" ; 12pager = "less -FR" ; 13map-syntax = [ "*.jenkinsfile:Groovy" "*.props:Java Properties" ]; 14}; 15 16themes . testtheme = '' 17This is a test theme. 18'' ; 19 20syntaxes . testsyntax = '' 21This is a test syntax. 22'' ; 23}; 24 25test . stubs . bat = { }; 26 27test . asserts . warnings . enable = true ; 28test . asserts . warnings . expected = [ 29'' 30Using programs.bat.themes as a string option is deprecated and will be 31removed in the future. Please change to using it as an attribute set 32instead. 33'' 34'' 35Using programs.bat.syntaxes as a string option is deprecated and will be 36removed in the future. Please change to using it as an attribute set 37instead. 38'' 39]; 40 41nmt . script = '' 42assertFileExists home-files/.config/bat/config 43assertFileContent home-files/.config/bat/config ${ 44pkgs . writeText "bat.expected" '' 45--map-syntax='*.jenkinsfile:Groovy' 46--map-syntax='*.props:Java Properties' 47--pager='less -FR' 48--theme='TwoDark' 49'' 50} 51 52assertFileExists home-files/.config/bat/themes/testtheme.tmTheme 53assertFileContent home-files/.config/bat/themes/testtheme.tmTheme ${ 54pkgs . writeText "bat.expected" '' 55This is a test theme. 56'' 57} 58 59assertFileExists home-files/.config/bat/syntaxes/testsyntax.sublime-syntax 60assertFileContent home-files/.config/bat/syntaxes/testsyntax.sublime-syntax ${ 61pkgs . writeText "bat.expected" '' 62This is a test syntax. 63'' 64} 65'' ; 66}; 67}