1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-12-15 21:41:09 +01:00

broot: use upstream defaults, allow all config options (#2644)

* broot: use freeformType for config

* broot: use defaults from upstream

closes #2395

* broot: generate shell function

* broot: add @dermetfan to CODEOWNERS

* broot: rename `config` option to `settings`

* broot: make example more idiomatic

Co-authored-by: Nicolas Berbiche <nic.berbiche@gmail.com>

Co-authored-by: Nicolas Berbiche <nic.berbiche@gmail.com>
This commit is contained in:
Robin Stumm 2022-09-26 20:36:06 +02:00 committed by GitHub
parent 9e7394523e
commit 65b65ce5ef
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 186 additions and 223 deletions

View file

@ -6,33 +6,46 @@ with lib;
config = {
programs.broot = {
enable = true;
modal = true;
settings.modal = true;
};
test.stubs.broot = { };
nmt.script = ''
assertFileExists home-files/.config/broot/conf.toml
assertFileContent home-files/.config/broot/conf.toml ${
pkgs.writeText "broot.expected" ''
modal = true
show_selection_mark = true
[[verbs]]
execution = ":parent"
invocation = "p"
[[verbs]]
execution = "$EDITOR {file}"
execution = "$EDITOR +{line} {file}"
invocation = "edit"
leave_broot = false
shortcut = "e"
[[verbs]]
execution = "$EDITOR {directory}/{subpath}"
invocation = "create {subpath}"
leave_broot = false
[[verbs]]
execution = "less {file}"
invocation = "view"
execution = "git difftool -y {file}"
invocation = "git_diff"
leave_broot = false
shortcut = "gd"
[[verbs]]
auto_exec = false
execution = "cp -r {file} {parent}/{file-stem}-{version}{file-dot-extension}"
invocation = "backup {version}"
key = "ctrl-b"
leave_broot = false
[[verbs]]
execution = "$SHELL"
invocation = "terminal"
key = "ctrl-t"
leave_broot = false
set_working_dir = true
[skin]
''