less: allow customization
Signed-off-by: Pamplemousse <xav.maso@gmail.com>
This commit is contained in:
parent
7c320a5325
commit
f23073f1da
8 changed files with 78 additions and 0 deletions
1
tests/modules/programs/less/default.nix
Normal file
1
tests/modules/programs/less/default.nix
Normal file
|
|
@ -0,0 +1 @@
|
|||
{ less-with-custom-keys = ./less-with-custom-keys.nix; }
|
||||
26
tests/modules/programs/less/less-with-custom-keys.nix
Normal file
26
tests/modules/programs/less/less-with-custom-keys.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
{
|
||||
programs.less = {
|
||||
enable = true;
|
||||
|
||||
keys = ''
|
||||
s back-line
|
||||
t forw-line
|
||||
'';
|
||||
};
|
||||
|
||||
test.stubs.less = { };
|
||||
|
||||
nmt.script = ''
|
||||
assertFileExists home-files/.lesskey
|
||||
assertFileContent home-files/.lesskey ${
|
||||
builtins.toFile "less.expected" ''
|
||||
s back-line
|
||||
t forw-line
|
||||
''
|
||||
}
|
||||
'';
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue