fork/home-manager
git clone https://git.julia.blue/fork/home-manager
cb09a968
master
1{ pkgs , ...} : 2 3let 4inherit ( pkgs . stdenv . hostPlatform ) isDarwin ; 5 6path = if isDarwin then 7"Library/Application Support/rbw/config.json" 8else 9".config/rbw/config.json" ; 10 11expected = pkgs . writeText "rbw-expected.json" '' 12{ 13"base_url": "bitwarden.example.com", 14"email": "name@example.com", 15"identity_url": "identity.example.com", 16"lock_timeout": 300, 17"pinentry": "@pinentry-gnome3@/bin/pinentry" 18} 19'' ; 20in { 21imports = [ ./rbw-stubs.nix ]; 22 23programs . rbw = { 24enable = true ; 25settings = { 26= "name@example.com" ; 27base_url = "bitwarden.example.com" ; 28identity_url = "identity.example.com" ; 29lock_timeout = 300 ; 30pinentry = "gnome3" ; 31}; 32}; 33 34nmt . script = '' 35assertFileExists home-files/ ${ path } 36assertFileContent home-files/ ${ path } ' ${ expected } ' 37'' ; 38}