diff options
-rw-r--r-- | common/commandline/starship-plain-text-symbols.toml | 18 | ||||
-rw-r--r-- | common/commandline/starship.nix | 13 | ||||
-rw-r--r-- | common/commandline/zsh.nix | 30 |
3 files changed, 31 insertions, 30 deletions
diff --git a/common/commandline/starship-plain-text-symbols.toml b/common/commandline/starship-plain-text-symbols.toml index 32126a0..b6412b4 100644 --- a/common/commandline/starship-plain-text-symbols.toml +++ b/common/commandline/starship-plain-text-symbols.toml | |||
@@ -73,6 +73,9 @@ symbol = "gcp " | |||
73 | [git_branch] | 73 | [git_branch] |
74 | symbol = "git " | 74 | symbol = "git " |
75 | 75 | ||
76 | [gleam] | ||
77 | symbol = "gleam " | ||
78 | |||
76 | [golang] | 79 | [golang] |
77 | symbol = "go " | 80 | symbol = "go " |
78 | 81 | ||
@@ -106,6 +109,9 @@ symbol = "memory " | |||
106 | [meson] | 109 | [meson] |
107 | symbol = "meson " | 110 | symbol = "meson " |
108 | 111 | ||
112 | [nats] | ||
113 | symbol = "nats " | ||
114 | |||
109 | [nim] | 115 | [nim] |
110 | symbol = "nim " | 116 | symbol = "nim " |
111 | 117 | ||
@@ -119,7 +125,9 @@ symbol = "ml " | |||
119 | symbol = "opa " | 125 | symbol = "opa " |
120 | 126 | ||
121 | [os.symbols] | 127 | [os.symbols] |
128 | AIX = "aix " | ||
122 | Alpaquita = "alq " | 129 | Alpaquita = "alq " |
130 | AlmaLinux = "alma " | ||
123 | Alpine = "alp " | 131 | Alpine = "alp " |
124 | Amazon = "amz " | 132 | Amazon = "amz " |
125 | Android = "andr " | 133 | Android = "andr " |
@@ -136,6 +144,7 @@ Garuda = "garu " | |||
136 | Gentoo = "gent " | 144 | Gentoo = "gent " |
137 | HardenedBSD = "hbsd " | 145 | HardenedBSD = "hbsd " |
138 | Illumos = "lum " | 146 | Illumos = "lum " |
147 | Kali = "kali " | ||
139 | Linux = "lnx " | 148 | Linux = "lnx " |
140 | Mabox = "mbox " | 149 | Mabox = "mbox " |
141 | Macos = "mac " | 150 | Macos = "mac " |
@@ -154,11 +163,14 @@ Pop = "pop " | |||
154 | Raspbian = "rasp " | 163 | Raspbian = "rasp " |
155 | Redhat = "rhl " | 164 | Redhat = "rhl " |
156 | RedHatEnterprise = "rhel " | 165 | RedHatEnterprise = "rhel " |
166 | RockyLinux = "rky " | ||
157 | Redox = "redox " | 167 | Redox = "redox " |
158 | Solus = "sol " | 168 | Solus = "sol " |
159 | SUSE = "suse " | 169 | SUSE = "suse " |
160 | Ubuntu = "ubnt " | 170 | Ubuntu = "ubnt " |
171 | Ultramarine = "ultm " | ||
161 | Unknown = "unk " | 172 | Unknown = "unk " |
173 | Void = "void " | ||
162 | Windows = "win " | 174 | Windows = "win " |
163 | 175 | ||
164 | [package] | 176 | [package] |
@@ -182,6 +194,9 @@ symbol = "purs " | |||
182 | [python] | 194 | [python] |
183 | symbol = "py " | 195 | symbol = "py " |
184 | 196 | ||
197 | [quarto] | ||
198 | symbol = "quarto " | ||
199 | |||
185 | [raku] | 200 | [raku] |
186 | symbol = "raku " | 201 | symbol = "raku " |
187 | 202 | ||
@@ -209,6 +224,9 @@ symbol = "sudo " | |||
209 | [swift] | 224 | [swift] |
210 | symbol = "swift " | 225 | symbol = "swift " |
211 | 226 | ||
227 | [typst] | ||
228 | symbol = "typst " | ||
229 | |||
212 | [terraform] | 230 | [terraform] |
213 | symbol = "terraform " | 231 | symbol = "terraform " |
214 | 232 | ||
diff --git a/common/commandline/starship.nix b/common/commandline/starship.nix index 1683765..5983d2e 100644 --- a/common/commandline/starship.nix +++ b/common/commandline/starship.nix | |||
@@ -2,20 +2,21 @@ inputs: {lib, ...}: { | |||
2 | home-manager.users.minijackson = { | 2 | home-manager.users.minijackson = { |
3 | programs.starship = { | 3 | programs.starship = { |
4 | enable = true; | 4 | enable = true; |
5 | enableZshIntegration = false; | 5 | enableZshIntegration = true; |
6 | 6 | ||
7 | settings = lib.mkMerge [ | 7 | settings = lib.mkMerge [ |
8 | { | 8 | { |
9 | directory = { | 9 | directory = { |
10 | fish_style_pwd_dir_length = 2; | 10 | fish_style_pwd_dir_length = 2; |
11 | style = "bold blue"; | 11 | repo_root_style = "bold cyan"; |
12 | style = "bold white"; | ||
13 | truncate_to_repo = false; | ||
12 | }; | 14 | }; |
15 | |||
13 | jobs.symbol = "+ "; | 16 | jobs.symbol = "+ "; |
17 | |||
14 | nix_shell.style = "bold blue"; | 18 | nix_shell.style = "bold blue"; |
15 | package = { | 19 | package.style = "bold green"; |
16 | disabled = true; | ||
17 | style = "bold green"; | ||
18 | }; | ||
19 | rust.style = "bold dimmed yellow"; | 20 | rust.style = "bold dimmed yellow"; |
20 | } | 21 | } |
21 | 22 | ||
diff --git a/common/commandline/zsh.nix b/common/commandline/zsh.nix index f2a052b..8f818dc 100644 --- a/common/commandline/zsh.nix +++ b/common/commandline/zsh.nix | |||
@@ -13,14 +13,11 @@ in | |||
13 | programs.zsh = { | 13 | programs.zsh = { |
14 | enable = true; | 14 | enable = true; |
15 | 15 | ||
16 | interactiveShellInit = '' | 16 | interactiveShellInit = lib.mkBefore '' |
17 | # Use cache file as is, to speed-up start time | 17 | # Use cache file as is, to speed-up start time |
18 | # This does mean we have to run once in a while: | 18 | # This does mean we have to run once in a while: |
19 | # compinit -d .config/zsh/.zcompdump | 19 | # compinit -d .config/zsh/.zcompdump |
20 | zstyle ':grml:completion:compinit' arguments -C | 20 | autoload -U compinit && compinit -C |
21 | |||
22 | source "${pkgs.grml-zsh-config}/etc/zsh/zshrc" | ||
23 | is4 && xsource "${pkgs.grml-zsh-config}/etc/zsh/keephack" | ||
24 | 21 | ||
25 | source "${pkgs.zsh-history-substring-search}/share/zsh-history-substring-search/zsh-history-substring-search.zsh" | 22 | source "${pkgs.zsh-history-substring-search}/share/zsh-history-substring-search/zsh-history-substring-search.zsh" |
26 | 23 | ||
@@ -29,22 +26,14 @@ in | |||
29 | local dim_fg_escape_code="${fgEscapeCode config.theme.colors.dimForeground}" | 26 | local dim_fg_escape_code="${fgEscapeCode config.theme.colors.dimForeground}" |
30 | 27 | ||
31 | ${builtins.readFile ../../dotfiles/zshrc} | 28 | ${builtins.readFile ../../dotfiles/zshrc} |
32 | |||
33 | autoload -Uz shmart-prompt-dir | ||
34 | zstyle -e ':prompt:grml*:*:items:path' token shmart-prompt-dir | ||
35 | } | ||
36 | |||
37 | # Grml's ZSH config overrides less variables | ||
38 | export ${ | ||
39 | lib.concatStringsSep " " ( | ||
40 | lib.mapAttrsToList (variable: value: "${variable}=\"${value}\"") config.programs.less.envVariables | ||
41 | ) | ||
42 | } | 29 | } |
43 | ''; | 30 | ''; |
44 | 31 | ||
45 | # otherwise it'll override the grml prompt | 32 | # not needed, since we're using starship |
46 | promptInit = ""; | 33 | promptInit = ""; |
47 | # Grml handles that, and supports cache (faster!!!) | 34 | # Use cache file as is, to speed-up start time |
35 | # This does mean we have to run once in a while: | ||
36 | # compinit -d .config/zsh/.zcompdump | ||
48 | enableGlobalCompInit = false; | 37 | enableGlobalCompInit = false; |
49 | 38 | ||
50 | syntaxHighlighting = { | 39 | syntaxHighlighting = { |
@@ -94,13 +83,6 @@ in | |||
94 | dotDir = ".config/zsh"; | 83 | dotDir = ".config/zsh"; |
95 | history.path = "${config.xdg.dataHome}/zsh/zsh_history"; | 84 | history.path = "${config.xdg.dataHome}/zsh/zsh_history"; |
96 | 85 | ||
97 | plugins = [ | ||
98 | { | ||
99 | name = "shmart-prompt-dir"; | ||
100 | src = inputs.shmart-prompt-dir; | ||
101 | file = "none"; | ||
102 | } | ||
103 | ]; | ||
104 | }; | 86 | }; |
105 | } | 87 | } |
106 | ) | 88 | ) |