summaryrefslogtreecommitdiff
path: root/home/starship.nix
blob: 8f0a5f69935b0d6b1c5404460d2aedb9a9d359d2 (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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
{
  config,
  lib,
  ...
}: {
  programs.starship = {
    enable = true;

    settings = {
      format = lib.concatStrings [
        "╭─ "
        "$username"
        "$hostname"
        "$git_branch"
        "$directory"
        "$line_break"
        "╰─ "
      ];

      username = {
        style_user = "bold cyan";
        style_root = "bold red";
        format = "[$user]($style) ";
        disabled = false;
        show_always = true;
      };

      hostname = {
        ssh_only = false;
        format = "on [$hostname](bold blue) ";
        disabled = false;
      };

      directory = {
        format = "[$path]($style)[$read_only]($read_only_style) ";
        truncation_length = -1;
        truncate_to_repo = false;
        truncation_symbol = "…/";
      };

      git_branch = {
        style = "bold purple";
        format = "at [$symbol$branch(:$remote_branch)]($style) ";
      };
    };
  };
}