aboutsummaryrefslogtreecommitdiff
path: root/home-manager/tests/modules/programs/readline/using-all-options.nix
blob: ab851020c2eb09fd247d416866d1caf952ec8cfa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{ config, lib, pkgs, ... }:

with lib;

{
  config = {
    programs.readline = {
      enable = true;

      bindings = { "\\C-h" = "backward-kill-word"; };

      variables = {
        bell-style = "audible";
        completion-map-case = true;
        completion-prefix-display-length = 2;
      };

      extraConfig = ''
        $if mode=emacs
        "\e[1~": beginning-of-line
        $endif
      '';
    };

    nmt.script = ''
      assertFileContent \
        home-files/.inputrc \
        ${./using-all-options.txt}
    '';
  };
}