repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by bugabinga

Merge branch 'trunk' of github.com:bugabinga/dotfiles into trunk

ae876e03b021d738c204932e109fc13d33e6101d

Oliver Jan Krylow <oliver@bugabinga.net> ·

unsigned

Browse filesCompare with HEAD

Changed files (40)

.gitignore

Modified
1 -bootstripper
2 -neovim/plugin
3 -bootstripper/bootstripper.com.dbg
4 -bootstripper/cosmopolitan
5 -bootstripper/win32/cross9
6 1 tresor/box_do_key
7 3 nushell/zoxide.nu
8 4 nushell/history.txt
9 5 nushell/plugin.nu
10 -<<<<<<< HEAD
11 7 neovim/profile.log
12 -=======
13 -profile.log
14 ->>>>>>> trunk
8 +neovim/plugin
15 9 neovim/profile.svg

PC-00625.symlinks

Modified
37 37 neovim
38 38 ~/AppData/Local/nvim
40 +bat/config
41 +~/AppData/Roaming/bat/config

bat/config

Added
new file mode 100644
1 +# apply colors from my terminal color scheme
2 +--theme=ansi
3 +--style=full
5 +--tabs 2
6 +#--show-all
7 +#--nonprintable-notation=unicode
9 +# use features of modern terminals
10 +--italic-text=always
12 +# Map some unknown file types to (hopefully similar) known ones
13 +--map-syntax "*.nu:Rust"
14 +--map-syntax ".stignore:Git Ignore"

bootstripper.java

Modified
5 5 import java.nio.file.Files;
6 6 import java.nio.file.LinkOption;
7 7 import java.nio.file.Path;
8 -import java.util.regex.Pattern;
8 +import java.util.List;
9 +import java.util.function.BiFunction;
10 11 class bootstripper {
11 - public static void main(String[] arguments) throws Throwable {
12 - var dorkfile_path_input = ".";
13 - if (arguments.length == 1) {
14 - dorkfile_path_input = arguments[0];
15 - } else if (arguments.length > 1) {
16 - usage();
17 - throw fail();
18 - }
19 - var dorkfiles_root = Path.of(dorkfile_path_input).toRealPath();
20 - log("Assuming dorkfiles root repo in {0}.",
21 - emphasize_local(dorkfiles_root.toString()));
22 - decrypt_secrets(dorkfiles_root.resolve("tresor"));
23 - var hostname = hostname();
24 - log("Hostname: {0}", emphasize_global(hostname));
25 - var symlinks_file = dorkfiles_root.resolve(hostname + ".symlinks");
26 - if (Files.exists(symlinks_file)) {
27 - create_symlinks(dorkfiles_root, symlinks_file);
28 - } else {
29 - throw fail("Expected a file containing symlinks at: {0}. Found nothing!",
30 - symlinks_file);
31 - }
32 - }
12 + public static void main(String[] arguments) throws Throwable {
13 + var dorkfile_path_input = ".";
14 + var do_clean = false;
34 - static void decrypt_secrets(Path secrets_root) throws Throwable {
35 - log("{0}:Decrypting files in {1} folder.", emphasize_global("TODO"),
36 - emphasize_local(secrets_root.getFileName().toString()));
37 - }
39 - static void create_symlinks(Path root, Path symlinks_file) throws Throwable {
40 - log("Creating symlinks as defined in {0} file.",
41 - emphasize_local(symlinks_file.getFileName().toString()));
42 - var lines = Files.readAllLines(symlinks_file);
43 - String source = null;
44 - String target = null;
45 - for (String line : lines) {
46 - if (line.isBlank())
47 - continue;
48 - if (source == null)
49 - source = line;
50 - else
51 - target = line;
52 - if (target != null) {
53 - link(root, source, target);
54 - source = null;
55 - target = null;
56 - }
57 - }
58 - }
60 - static void link(Path root, String source, String target) throws Throwable {
61 - var home = System.getProperty("user.home");
62 - var source_path = root.resolve(source).toAbsolutePath();
63 - var target_path = Path.of(target.replace("~", home)).toAbsolutePath();
64 - var is_directory = Files.isDirectory(source_path);
65 - if (Files.exists(target_path, LinkOption.NOFOLLOW_LINKS)) {
66 - if (Files.exists(target_path)) {
67 - log("\nOK {0} already exists!\nNot linking {1}.",
68 - emphasize_global(target_path.toString()),
69 - emphasize_local(source_path.toString()));
70 - return;
71 - } else {
72 - log("\nNOPE {0} exists, but it points into nirvana. Removing broken link!",
73 - target_path.toString());
74 - Files.delete(target_path);
75 - }
76 - }
77 - log("\nLINK {0} TO {1}.", emphasize_local(source_path.toString()),
78 - emphasize_local(target_path.toString()));
79 - Files.createDirectories(target_path.getParent());
80 - try {
81 - Files.createSymbolicLink(target_path, source_path);
82 - } catch (Exception __) {
83 - /*
84 - * Creating symbolic links on Windows only recently became possible
85 - * without admin rights. And even that, is only available in Developer
86 - * Mode. However, most tools (including JDK) have not yet adapted to this
87 - * change and still require admin rights. Until that is fixed, we escape
88 - * to a system tool that is known to behave correctly in this regard.
89 - */
90 - var operating_system = System.getProperty("os.name");
91 - if (operating_system.toLowerCase().contains("win")) {
92 - var process = new ProcessBuilder();
93 - var command = process.command();
94 - command.add("cmd.exe");
95 - command.add("/c");
96 - command.add("mklink");
97 - if (is_directory) {
98 - command.add("/d");
16 + if (arguments.length == 1) {
17 + if ("clean".equals(arguments[0])) {
18 + do_clean = true;
19 + } else {
20 + dorkfile_path_input = arguments[0];
21 + }
22 + } else if (arguments.length == 2) {
23 + if ("clean".equals(arguments[0])) {
24 + do_clean = true;
25 + dorkfile_path_input = arguments[1];
26 + } else {
27 + usage();
28 + throw fail();
29 + }
30 + } else if (arguments.length > 2) {
31 + usage();
32 + throw fail();
33 + }
34 + var dorkfiles_root = Path.of(dorkfile_path_input).toRealPath();
35 + log("Assuming dorkfiles root repo in {0}.",
36 + emphasize_local(dorkfiles_root.toString()));
37 + if (!do_clean)
38 + decrypt_secrets(dorkfiles_root.resolve("tresor"));
39 + var hostname = hostname();
40 + log("Hostname: {0}", emphasize_global(hostname));
41 + var symlinks_file = dorkfiles_root.resolve(hostname + ".symlinks");
42 + if (Files.exists(symlinks_file)) {
43 + if (do_clean)
44 + delete_symlinks(dorkfiles_root, symlinks_file);
45 + else
46 + create_symlinks(dorkfiles_root, symlinks_file);
47 + } else {
48 + throw fail("Expected a file containing symlinks at: {0}. Found nothing!",
49 + symlinks_file);
100 - command.add(target_path.toString());
101 - command.add(source_path.toString());
102 - log(command.toString());
103 - process.inheritIO().start().onExit().join();
104 - } else {
105 - __.printStackTrace();
106 - throw fail("Could not create symbolic link!");
107 - }
109 - }
111 - static String hostname() throws Exception {
112 - var process_builder = new ProcessBuilder().command("hostname");
113 - Process process;
114 - try {
115 - process = process_builder.start().onExit().join();
116 - } catch (IOException __) {
117 - process = new ProcessBuilder()
53 + static void decrypt_secrets(Path secrets_root) throws Throwable {
54 + log("{0}:Decrypting files in {1} folder.", emphasize_global("TODO"),
55 + emphasize_local(secrets_root.getFileName().toString()));
56 + }
58 + static void create_symlinks(Path root, Path symlinks_file) throws Throwable {
59 + log("Creating symlinks as defined in {0} file.",
60 + emphasize_local(symlinks_file.getFileName().toString()));
61 + var lines = Files.readAllLines(symlinks_file);
62 + for_each_mapping(lines, (source, target) -> link(root, source, target));
63 + }
65 + static void delete_symlinks(Path root, Path symlinks_file) throws Throwable {
66 + log("Deleting symlinks as defined in {0} file.",
67 + emphasize_local(symlinks_file.getFileName().toString()));
68 + var lines = Files.readAllLines(symlinks_file);
69 + for_each_mapping(lines, (source, target) -> delete(root, source, target));
70 + }
72 + static void delete(Path root, String source, String target) throws Throwable {
73 + var home = System.getProperty("user.home");
74 + var source_path = root.resolve(source).toAbsolutePath();
75 + var target_path = Path.of(target.replace("~", home)).toAbsolutePath();
77 + if (Files.exists(target_path, LinkOption.NOFOLLOW_LINKS)) {
78 + var symlink_target = target_path.toRealPath();
79 + if (symlink_target.compareTo(source_path) == 0) {
80 + log("\nOK {0} exists and points to {1} in dorkfiles!\nDeleting {0}.",
81 + emphasize_global(target_path.toString()),
82 + emphasize_local(source_path.toString()));
83 + // a symlink is always a file. no need to handle folders
84 + Files.delete(target_path);
85 + } else {
86 + log("\nNOPE {0} exists, but it points outside of dorkfiles! Clean manually.",
87 + target_path.toString());
88 + }
89 + }
90 + }
92 + static void link(Path root, String source, String target) throws Throwable {
93 + var home = System.getProperty("user.home");
94 + var source_path = root.resolve(source).toAbsolutePath();
95 + var target_path = Path.of(target.replace("~", home)).toAbsolutePath();
96 + var is_directory = Files.isDirectory(source_path);
97 + if (Files.exists(target_path, LinkOption.NOFOLLOW_LINKS)) {
98 + if (Files.exists(target_path)) {
99 + log("\nOK {0} already exists!\nNot linking {1}.",
100 + emphasize_global(target_path.toString()),
101 + emphasize_local(source_path.toString()));
102 + return;
103 + } else {
104 + log("\nNOPE {0} exists, but it points into nirvana. Removing broken link!",
105 + target_path.toString());
106 + Files.delete(target_path);
109 + log("\nLINK {0} TO {1}.", emphasize_local(source_path.toString()),
110 + emphasize_local(target_path.toString()));
111 + Files.createDirectories(target_path.getParent());
112 + try {
113 + Files.createSymbolicLink(target_path, source_path);
114 + } catch (Exception __) {
115 + /*
116 + * Creating symbolic links on Windows only recently became possible
117 + * without admin rights. And even that, is only available in Developer
118 + * Mode. However, most tools (including JDK) have not yet adapted to this
119 + * change and still require admin rights. Until that is fixed, we escape
120 + * to a system tool that is known to behave correctly in this regard.
121 + */
122 + var operating_system = System.getProperty("os.name");
123 + if (operating_system.toLowerCase().contains("win")) {
124 + var process = new ProcessBuilder();
125 + var command = process.command();
126 + command.add("cmd.exe");
127 + command.add("/c");
128 + command.add("mklink");
129 + if (is_directory) {
130 + command.add("/d");
132 + command.add(target_path.toString());
133 + command.add(source_path.toString());
134 + log(command.toString());
135 + process.inheritIO().start().onExit().join();
136 + } else {
137 + __.printStackTrace();
138 + throw fail("Could not create symbolic link!");
143 + static String hostname() throws Exception {
144 + var process_builder = new ProcessBuilder().command("hostname");
145 + Process process;
146 + try {
147 + process = process_builder.start().onExit().join();
148 + } catch (IOException __) {
149 + process = new ProcessBuilder()
118 150 .command("hostnamectl", "hostname")
119 151 .start()
120 152 .onExit()
121 153 .join();
155 + try (var reader = new InputStreamReader(process.getInputStream())) {
156 + int character = -1;
157 + var output = new StringBuilder();
158 + while ((character = reader.read()) != -1) {
159 + if (character == '\n' || character == '\r')
160 + continue;
161 + output.append((char) character);
163 + var name = output.toString();
164 + if( "localhost".equals(name) ) {
165 + // we are inside termux
166 + assert System.getenv("PREFIX") != null;
167 + return "termux";
169 + return name;
123 - try (var reader = new InputStreamReader(process.getInputStream())) {
124 - int character = -1;
125 - var output = new StringBuilder();
126 - while ((character = reader.read()) != -1) {
127 - if (character == '\n' || character == '\r')
128 - continue;
129 - output.append((char)character);
130 - }
131 - var name = output.toString();
132 - if( "localhost".equals(name) ) {
133 - // we are inside termux
134 - assert System.getenv("PREFIX") != null;
135 - return "termux";
136 - }
137 - return output.toString();
173 + static void usage() {
174 + log("Bootstraps bugabingas {0}.", emphasize_local("dorkfiles"));
175 + log("{0}: java bootstripper.java [clean] [dotfiles root path]",
176 + emphasize_global("Usage"));
139 - }
141 - static void usage() {
142 - log("Bootstraps bugabingas {0}.", emphasize_local("dorkfiles"));
143 - log("{0}: java bootstripper.java [dotfiles root path]",
144 - emphasize_global("Usage"));
145 - }
179 + static String emphasize_global(String message) {
180 + return "\033[4m" + message + "\033[0m";
147 - static String emphasize_global(String message) {
148 - return "\033[4m" + message + "\033[0m";
149 - }
183 + static String emphasize_local(String message) {
184 + return "\033[3m" + message + "\033[0m";
151 - static String emphasize_local(String message) {
152 - return "\033[3m" + message + "\033[0m";
153 - }
187 + static Throwable fail(String message, Object... arguments) {
188 + log(message, arguments);
189 + return fail();
155 - static Throwable fail(String message, Object... arguments) {
156 - log(message, arguments);
157 - return fail();
158 - }
192 + static Throwable fail() {
193 + System.exit(-1);
194 + return new Throwable("use 'throw fail()' for control flow");
160 - static Throwable fail() {
161 - System.exit(-1);
162 - return new Throwable("use 'throw fail()' for control flow");
163 - }
197 + static void log(String message, Object... arguments) {
198 + System.out.println(format(message, arguments));
165 - static void log(String message, Object... arguments) {
166 - System.out.println(format(message, arguments));
167 - }
201 + static interface ThrowUp<A, B> {
202 + default Throwable gurgh(A a, B b) {
203 + try {
204 + apply(a, b);
205 + return null;
206 + } catch (Throwable vomit) {
207 + return vomit;
211 + void apply(A a, B b) throws Throwable;
214 + static void for_each_mapping(List<String> lines, ThrowUp<String, String> block)
215 + throws Throwable {
216 + String source = null;
217 + String target = null;
218 + for (String line : lines) {
219 + if (line.isBlank())
220 + continue;
221 + if (source == null)
222 + source = line;
223 + else
224 + target = line;
225 + if (target != null) {
226 + var vomit = block.gurgh(source, target);
227 + if (vomit != null)
228 + throw vomit;
229 + source = null;
230 + target = null;

git/gitconfig

Modified
1 1 [user]
2 2 name = Oliver Jan Krylow
3 - email = olver@bugabinga.net
3 + email = oliver@bugabinga.net
5 5 [core]
6 6 editor = hx

helix/config.toml

Modified
1 -theme = "nugu"
1 +theme = "nugu-light"
3 3 [editor]
4 4 shell = ["nu", "--commands"]
8 8 line-number = "relative"
9 9 rulers = [81, 121, 141]
11 -auto-completion = true
11 +auto-completion = false
12 12 completion-trigger-len = 3
13 13 auto-info = true
14 -auto-pairs = true
14 +auto-pairs = false
15 15 auto-format = true
16 +auto-save = true
17 18 idle-timeout = 200
19 20 scrolloff = 5
20 21 scroll-lines = 1
22 -cursorline = true
23 23 color-modes = true
24 -auto-save = true
25 -bufferline = "always"
24 +bufferline = "multiple"
27 26 [editor.statusline]
28 27 left = [
34 33 "position-percentage",
36 35 center = [
36 + "version-control",
37 + "separator",
37 38 "file-name",
39 + "spacer",
40 + "file-modification-indicator",
38 41 "separator",
39 42 "file-encoding",
40 43 "file-line-ending",
41 44 "file-type",
43 -right = ["diagnostics", "spacer", "spinner"]
46 +right = [
47 + "diagnostics",
48 + "spacer",
49 + "spinner"
44 51 separator = "·"
52 +mode.normal = ""
53 +mode.insert = ""
54 +mode.select = ""
46 56 [editor.lsp]
47 57 display-messages = true
58 +display-inlay-hints = true
49 61 [editor.cursor-shape]
50 62 normal = "block"
62 74 [editor.whitespace.characters]
63 75 space = "·"
64 76 nbsp = "⍽"
65 -tab = "─"
66 -tabpad = "╴"
67 77 newline = "⏎"
69 79 [editor.indent-guides]
70 -render = true
80 +render = false
71 81 character = "▏"
72 82 skip-levels = 2
84 +[editor.soft-wrap]
85 +enable = true
87 +[keys.normal]
88 +ret = ["add_newline_below","move_line_down"]
89 +A-ret = ["add_newline_above", "move_line_up"]
91 +# move current line up
92 +A-up = ["extend_to_line_bounds", "delete_selection", "move_line_up", "paste_before"]
93 +A-k = ["extend_to_line_bounds", "delete_selection", "move_line_up", "paste_before"]
95 +# move current line down
96 +A-down = ["extend_to_line_bounds", "delete_selection", "paste_after"]
97 +A-j = ["extend_to_line_bounds", "delete_selection", "paste_after"]
99 +[keys.insert]
100 +"C-space" = "completion"

helix/languages.toml

Added
new file mode 100644
1 +[[language]]
2 +name = "java"
3 +auto-format = true
4 +# language-server = { command = "jdtls" }
5 +config = { "settings" = { "java" = { "saveActions" = { "organizeImports" = true } } } }

helix/systemd/helix-dark-mode.service

Added
new file mode 100644
1 +[Unit]
2 +Description=Helix Dark Mode Service
3 +Documentation=https://github.com/helix-editor/helix/issues/2158
4 +After=gnome-session.target
6 +[Service]
7 +Type=simple
8 +RestartSec=5
9 +Restart=always
10 +ExecStart=%h/.config/helix/themes/dark-mode/monitor.sh
12 +[Install]
13 +WantedBy=gnome-session.target

helix/themes/dark-mode/disable.sh

Added
new file mode 100755
1 +#!/usr/bin/env bash
3 +# Stop the service immediately and disables it from starting on boot.
4 +systemctl --user disable --now helix-dark-mode.service

helix/themes/dark-mode/enable.sh

Added
new file mode 100755
1 +#!/usr/bin/env bash
3 +# Enables the service to start on boot and also starts it up immediately.
4 +systemctl --user enable --now helix-dark-mode.service

helix/themes/dark-mode/monitor.sh

Added
new file mode 100755
1 +#!/usr/bin/env bash
3 +gsettings monitor org.gnome.desktop.interface color-scheme \
4 + | xargs -L1 bash -c "source ${HOME}/.config/helix/themes/dark-mode/update.sh"

helix/themes/dark-mode/update.sh

Added
new file mode 100644
1 +#!/usr/bin/env bash
3 +# Fail early, fail often.
4 +set -eu -o pipefail
6 +if [[ "$1" == "default" ]]; then
7 + # Update Helix Editor config to use light theme.
8 + sed -i 's/theme = ".*"/theme = "nugu-light"/' ${HOME}/.config/helix/config.toml
9 +else
10 + # Update Helix Editor config to use dark theme.
11 + sed -i 's/theme = ".*"/theme = "nugu-dark"/' ${HOME}/.config/helix/config.toml
12 +fi
14 +# reload configuration of running helix instances
15 +pkill -USR1 hx

helix/themes/gpt-dark.toml

Added
new file mode 100644
1 +inherits = "base16_default_dark"
3 +"ui.virtual.ruler" = { bg = "base01" }
4 +"comment" = { fg = "base03", modifiers = ["italic", "bold"] }
6 +[palette]
7 +base00 = "#181818" # Default Background
8 +base01 = "#282828" # Lighter Background (Used for status bars, line number and folding marks)
9 +base02 = "#383838" # Selection Background
10 +base03 = "#585858" # Comments, Invisibles, Line Highlighting
11 +base04 = "#b8b8b8" # Dark Foreground (Used for status bars)
12 +base05 = "#d8d8d8" # Default Foreground, Caret, Delimiters, Operators
13 +base06 = "#e8e8e8" # Light Foreground (Not often used)
14 +base07 = "#f8f8f8" # Light Background (Not often used)
15 +base08 = "#ab4642" # Variables, XML Tags, Markup Link Text, Markup Lists, Diff Deleted
16 +base09 = "#dc9656" # Integers, Boolean, Constants, XML Attributes, Markup Link Url
17 +base0A = "#f7ca88" # Classes, Markup Bold, Search Text Background
18 +base0B = "#a1b56c" # Strings, Inherited Class, Markup Code, Diff Inserted
19 +base0C = "#86c1b9" # Support, Regular Expressions, Escape Characters, Markup Quotes
20 +base0D = "#7cafc2" # Functions, Methods, Attribute IDs, Headings
21 +base0E = "#ba8baf" # Keywords, Storage, Selector, Markup Italic, Diff Changed
22 +base0F = "#a16946" # Deprecated, Opening/Closing Embedded Language Tags, e.g. <?php ?>

helix/themes/gpt-light.toml

Added
new file mode 100644
1 +inherits = "base16_default_light"
3 +"ui.virtual.ruler" = { bg = "base01" }
4 +"comment" = { fg = "base03", modifiers = ["italic", "bold"] }
6 +[palette]
7 +base00 = "#f2f2f2" # Default Background
8 +base01 = "#dcdcdc" # Lighter Background (Used for status bars, line number and folding marks)
9 +base02 = "#c2c2c2" # Selection Background
10 +base03 = "#8a8a8a" # Comments, Invisibles, Line Highlighting
11 +base04 = "#2e2e2e" # Dark Foreground (Used for status bars)
12 +base05 = "#1a1a1a" # Default Foreground, Caret, Delimiters, Operators
13 +base06 = "#050505" # Light Foreground (Not often used)
14 +base07 = "#000000" # Light Background (Not often used)
15 +base08 = "#8c3532" # Variables, XML Tags, Markup Link Text, Markup Lists, Diff Deleted
16 +base09 = "#b45f31" # Integers, Boolean, Constants, XML Attributes, Markup Link Url
17 +base0A = "#b88e36" # Classes, Markup Bold, Search Text Background
18 +base0B = "#6c782e" # Strings, Inherited Class, Markup Code, Diff Inserted
19 +base0C = "#4d7474" # Support, Regular Expressions, Escape Characters, Markup Quotes
20 +base0D = "#4b6988" # Functions, Methods, Attribute IDs, Headings
21 +base0E = "#6c5b7b" # Keywords, Storage, Selector, Markup Italic, Diff Changed
22 +base0F = "#5c4343" # Deprecated, Opening/Closing Embedded Language Tags, e.g. <?php ?>

helix/themes/nugu-dark.toml

Added
new file mode 100644
1 +# SYNTAX THEME
2 +# modifiers:
3 +# # - bold
4 +# - dim
5 +# - italic
6 +# - slow_blink
7 +# - rapid_blink
8 +# - reversed
9 +# - hidden
10 +# - crossed_out
12 +# underline:
13 +# - style
14 +# - line
15 +# - curl
16 +# - dashed
17 +# - dotted
18 +# - double_line
19 +# - color
21 +"comment" = { fg = "important_global", modifiers = ["bold"] }
22 +"string" = { fg = "important_local", modifiers = ["italic"] }
23 +"comment.block.documentation" = { fg = "minor", modifiers = ["dim"] }
24 +"punctuation" = { fg = "minor" }
25 +"keyword" = { fg = "minor" }
26 +"tag" = { fg = "minor" }
27 +"keyword.control.return" = { modifiers = ["bold"], underline.style = "line" }
28 +"keyword.control.exception" = { modifiers = ["bold"], underline.style = "line" }
29 +"operator" = { fg = "minor" }
30 +"variable.parameter" = { fg = "focus", modifiers = ["bold"] }
32 +"markup.heading" = { fg = "important_global", modifiers = [
33 + "bold",
34 +], underline.style = "double_line" }
35 +"markup.heading.marker" = { fg = "minor" }
36 +"markup.list" = "minor"
37 +"markup.bold" = { modifiers = ["bold"] }
38 +"markup.italic" = { modifiers = ["italic"] }
39 +"markup.strikethrough" = { modifiers = ["crossed_out"] }
40 +"markup.link.url" = "accent"
41 +"markup.link.text" = "important_local"
42 +"markup.link.label" = "important_global"
43 +"markup.quote" = { fg = "important_local", modifiers = ["italic"] }
44 +"markup.raw.inline" = { fg = "important_local" }
45 +"markup.raw.block" = { fg = "important_global" }
47 +"diff.plus" = { fg = "important_local", modifiers = ["bold"] }
48 +"diff.delta" = { fg = "unfocus" }
49 +"diff.minus" = { fg = "focus", modifiers = ["crossed_out"] }
51 +"ui.background" = { fg = "normal", bg = "backdrop" }
52 +"ui.background.separator" = { fg = "ui_minor" }
54 +"ui.cursor" = { fg = "normal", bg = "ui_accent" }
55 +"ui.cursor.primary" = { fg = "normal", bg = "ui_accent" }
56 +"ui.cursor.match" = { fg = "normal", bg = "ui_unfocus", modifiers = [
57 + "slow_blink",
58 +] }
60 +"ui.cursorline.primary" = { underline = { style = "line", color = "ui_unfocus" } }
62 +"ui.selection" = { fg = "normal", bg = "ui_unfocus" }
63 +"ui.selection.primary" = { fg = "normal", bg = "ui_important_local" }
65 +"ui.linenr" = { fg = "ui_minor", bg = "backdrop" }
66 +"ui.linenr.selected" = { fg = "ui_focus" }
68 +"ui.statusline" = { fg = "ui_normal", bg = "ui_backdrop" }
69 +"ui.statusline.separator" = { fg = "ui_unfocus", bg = "ui_backdrop" }
70 +"ui.statusline.insert" = { fg = "ui_important_global", modifiers = ["bold"] }
71 +"ui.statusline.select" = { fg = "ui_focus", modifiers = ["bold"] }
72 +"ui.statusline.inactive" = { fg = "ui_minor", bg = "ui_backdrop" }
74 +"ui.bufferline" = { fg = "ui_normal", bg = "ui_backdrop" }
75 +"ui.bufferline.active" = { fg = "ui_important_global", bg = "ui_unfocus", modifiers = [
76 + "bold",
77 +], underline = { style = "double_line", color = "ui_important_global" } }
79 +"ui.gutter" = { bg = "backdrop" }
81 +"ui.debug.breakpoint" = { fg = "ui_important_global" }
82 +"ui.debug.active" = { fg = "ui_important_global" }
84 +"ui.window" = { fg = "ui_unfocus", bg = "ui_backdrop" }
86 +"ui.help" = { fg = "ui_important_global", bg = "ui_backdrop" }
88 +"ui.text" = { fg = "normal", bg = "backdrop" }
89 +"ui.text.focus" = { fg = "ui_focus" }
90 +"ui.text.info" = { fg = "ui_normal", bg = "ui_backdrop" }
91 +"ui.text.inactive" = { fg = "ui_minor" }
93 +"ui.menu" = { fg = "ui_normal", bg = "ui_backdrop" }
94 +"ui.menu.selected" = { fg = "ui_focus", bg = "ui_backdrop", modifiers = [
95 + "bold",
96 +] }
97 +"ui.menu.scroll" = { fg = "ui_accent", bg = "ui_backdrop" }
99 +"ui.popup" = { fg = "normal", bg = "backdrop" }
100 +"ui.popup.info" = { fg = "ui_minor", bg = "ui_backdrop" }
102 +"ui.highlight" = { bg = "ui_focus" }
103 +"ui.highlight.frameline" = { bg = "ui_important_global" }
105 +"ui.virtual.ruler" = { bg = "ui_unfocus" }
106 +"ui.virtual.whitespace" = { fg = "ui_unfocus" }
107 +"ui.virtual.inlay-hint" = { fg = "ui_minor" }
109 +"error" = { bg = "error" }
110 +"warning" = { bg = "warning" }
111 +"info" = { bg = "info" }
112 +"hint" = { fg = "info", modifiers = ["dim"] }
113 +"diagnostic.error" = { underline = { style = "double_line", color = "error" } }
114 +"diagnostic.warning" = { underline = { style = "double_line", color = "warning" } }
115 +"diagnostic.info" = { underline = { style = "double_line", color = "info" } }
116 +"diagnostic.hint" = { underline = { style = "double_line", color = "info" }, modifiers = [
117 + "dim",
118 +] }
119 +"special" = { fg = "debug" }
121 +[palette]
123 +accent = "#800080"
124 +backdrop = "#131313"
125 +debug = "#3dd45d"
126 +error = "#740523"
127 +focus = "#a5bdb6"
128 +important_global = "#8e58cc"
129 +important_local = "#7a3bc3"
130 +info = "#4187a7"
131 +minor = "#727272"
132 +normal = "#cfcfcf"
133 +ui_accent = "#7a067a"
134 +ui_backdrop = "#000000"
135 +ui_focus = "#788984"
136 +ui_important_global = "#5f368d"
137 +ui_important_local = "#4c2b72"
138 +ui_minor = "#424242"
139 +ui_normal = "#e2e2e2"
140 +ui_unfocus = "#121212"
141 +unfocus = "#3f4543"
142 +warning = "#a7802d"

helix/themes/nugu-light.toml

Added
new file mode 100644
1 +# SYNTAX THEME
2 +# modifiers:
3 +# # - bold
4 +# - dim
5 +# - italic
6 +# - slow_blink
7 +# - rapid_blink
8 +# - reversed
9 +# - hidden
10 +# - crossed_out
12 +# underline:
13 +# - style
14 +# - line
15 +# - curl
16 +# - dashed
17 +# - dotted
18 +# - double_line
19 +# - color
21 +"comment" = { fg = "important_global", modifiers = ["bold"] }
22 +"string" = { fg = "important_local", modifiers = ["italic"] }
23 +"comment.block.documentation" = { fg = "minor", modifiers = ["dim"] }
24 +"punctuation" = { fg = "minor" }
25 +"keyword" = { fg = "minor" }
26 +"tag" = { fg = "minor" }
27 +"keyword.control.return" = { modifiers = ["bold"], underline.style = "line" }
28 +"keyword.control.exception" = { modifiers = ["bold"], underline.style = "line" }
29 +"operator" = { fg = "minor" }
30 +"variable.parameter" = { fg = "focus", modifiers = ["bold"] }
32 +"markup.heading" = { fg = "important_global", modifiers = [
33 + "bold",
34 +], underline.style = "double_line" }
35 +"markup.heading.marker" = { fg = "minor" }
36 +"markup.list" = "minor"
37 +"markup.bold" = { modifiers = ["bold"] }
38 +"markup.italic" = { modifiers = ["italic"] }
39 +"markup.strikethrough" = { modifiers = ["crossed_out"] }
40 +"markup.link.url" = "accent"
41 +"markup.link.text" = "important_local"
42 +"markup.link.label" = "important_global"
43 +"markup.quote" = { fg = "important_local", modifiers = ["italic"] }
44 +"markup.raw.inline" = { fg = "important_local" }
45 +"markup.raw.block" = { fg = "important_global" }
47 +"diff.plus" = { fg = "important_local", modifiers = ["bold"] }
48 +"diff.delta" = { fg = "unfocus" }
49 +"diff.minus" = { fg = "focus", modifiers = ["crossed_out"] }
51 +"ui.background" = { fg = "normal", bg = "backdrop" }
52 +"ui.background.separator" = { fg = "ui_minor" }
54 +"ui.cursor" = { fg = "normal", bg = "ui_accent" }
55 +"ui.cursor.primary" = { fg = "normal", bg = "ui_accent" }
56 +"ui.cursor.match" = { fg = "normal", bg = "ui_unfocus", modifiers = [
57 + "slow_blink",
58 +] }
60 +"ui.cursorline.primary" = { underline = { style = "line", color = "ui_unfocus" } }
62 +"ui.selection" = { fg = "normal", bg = "ui_unfocus" }
63 +"ui.selection.primary" = { fg = "normal", bg = "ui_important_local" }
65 +"ui.linenr" = { fg = "ui_minor", bg = "backdrop" }
66 +"ui.linenr.selected" = { fg = "ui_focus" }
68 +"ui.statusline" = { fg = "ui_normal", bg = "ui_backdrop" }
69 +"ui.statusline.separator" = { fg = "ui_unfocus", bg = "ui_backdrop" }
70 +"ui.statusline.insert" = { fg = "ui_important_global", modifiers = ["bold"] }
71 +"ui.statusline.select" = { fg = "ui_focus", modifiers = ["bold"] }
72 +"ui.statusline.inactive" = { fg = "ui_minor", bg = "ui_backdrop" }
74 +"ui.bufferline" = { fg = "ui_normal", bg = "ui_backdrop" }
75 +"ui.bufferline.active" = { fg = "ui_important_global", bg = "ui_unfocus", modifiers = [
76 + "bold",
77 +], underline = { style = "double_line", color = "ui_important_global" } }
79 +"ui.gutter" = { bg = "backdrop" }
81 +"ui.debug.breakpoint" = { fg = "ui_important_global" }
82 +"ui.debug.active" = { fg = "ui_important_global" }
84 +"ui.window" = { fg = "ui_unfocus", bg = "ui_backdrop" }
86 +"ui.help" = { fg = "ui_important_global", bg = "ui_backdrop" }
88 +"ui.text" = { fg = "normal", bg = "backdrop" }
89 +"ui.text.focus" = { fg = "ui_focus" }
90 +"ui.text.info" = { fg = "ui_normal", bg = "ui_backdrop" }
91 +"ui.text.inactive" = { fg = "ui_minor" }
93 +"ui.menu" = { fg = "ui_normal", bg = "ui_backdrop" }
94 +"ui.menu.selected" = { fg = "ui_focus", bg = "ui_backdrop", modifiers = [
95 + "bold",
96 +] }
97 +"ui.menu.scroll" = { fg = "ui_accent", bg = "ui_backdrop" }
99 +"ui.popup" = { fg = "normal", bg = "backdrop" }
100 +"ui.popup.info" = { fg = "ui_minor", bg = "ui_backdrop" }
102 +"ui.highlight" = { bg = "ui_focus" }
103 +"ui.highlight.frameline" = { bg = "ui_important_global" }
105 +"ui.virtual.ruler" = { bg = "ui_unfocus" }
106 +"ui.virtual.whitespace" = { fg = "ui_unfocus" }
107 +"ui.virtual.inlay-hint" = { fg = "ui_minor" }
109 +"error" = { bg = "error" }
110 +"warning" = { bg = "warning" }
111 +"info" = { bg = "info" }
112 +"hint" = { fg = "info", modifiers = ["dim"] }
113 +"diagnostic.error" = { underline = { style = "double_line", color = "error" } }
114 +"diagnostic.warning" = { underline = { style = "double_line", color = "warning" } }
115 +"diagnostic.info" = { underline = { style = "double_line", color = "info" } }
116 +"diagnostic.hint" = { underline = { style = "double_line", color = "info" }, modifiers = [
117 + "dim",
118 +] }
119 +"special" = { fg = "debug" }
121 +[palette]
123 +accent = "#800080"
124 +backdrop = "#e3e3e3"
125 +debug = "#3dd45d"
126 +error = "#f27a9a"
127 +focus = "#646464"
128 +important_global = "#48256e"
129 +important_local = "#643398"
130 +info = "#e7f0f3"
131 +minor = "#878787"
132 +normal = "#494949"
133 +ui_accent = "#d43dd4"
134 +ui_backdrop = "#c7c7c7"
135 +ui_focus = "#646464"
136 +ui_important_global = "#9170b5"
137 +ui_important_local = "#ae95c8"
138 +ui_minor = "#d0d0d0"
139 +ui_normal = "#929292"
140 +ui_unfocus = "#c9c9c9"
141 +unfocus = "#c9c9c9"
142 +warning = "#f1e8d6"

helix/themes/nugu.toml

Deleted
deleted file mode 100644
1 -# SYNTAX THEME
2 -# modifiers:
3 -#
4 -# - bold
5 -# - dim
6 -# - italic
7 -# - underlined
8 -# - slow_blink
9 -# - rapid_blink
10 -# - reversed
11 -# - hidden
12 -# - crossed_out
14 -"string" = { fg = "accent", modifiers = ["italic"] }
15 -"string.regexp" = { fg = "accent", bg = "minor_backdrop" }
16 -"string.special" = { fg = "info", bg = "minor_backdrop" }
17 -"comment" = { fg = "important_global", modifiers = ["bold"] }
18 -"comment.block.documentation" = { fg = "minor", modifiers = ["dim"] }
19 -"punctuation" = { fg = "minor" }
20 -"keyword" = { fg = "minor" }
21 -"keyword.control.return" = { modifiers = ["bold", "underlined"] }
22 -"keyword.control.exception" = { modifiers = ["bold", "underlined"] }
23 -"operator" = { fg = "minor" }
25 -"program.import_declaration.import" = { fg = "debug" }
27 -"markup" = "debug"
28 -"markup.heading" = { fg = "important_global", modifiers = ["bold"] }
29 -"markup.list" = "minor"
30 -"markup.bold" = { fg = "normal", modifiers = ["bold"] }
31 -"markup.italic" = { fg = "normal", modifiers = ["italic"] }
32 -"markup.link.url" = "minor"
33 -"markup.link.text" = "important_local"
34 -"markup.link.label" = "important_global"
35 -"markup.quote" = { fg = "important_local", modifiers = ["italic"] }
36 -"markup.raw.inline" = { fg = "accent" }
37 -"markup.raw.block" = { fg = "accent", modifiers = ["dim"] }
39 -"diff.plus" = { fg = "important_local", modifiers = ["bold"] }
40 -"diff.delta" = { fg = "ui_normal" }
41 -"diff.minus" = { fg = "minor", modifiers = ["crossed_out"] }
43 -# UI THEME
44 -"ui.background" = { bg = "backdrop" }
46 -"ui.cursor" = { bg = "ui_cursor" }
47 -"ui.cursor.primary" = { fg = "important_global", bg = "ui_cursor" }
48 -"ui.cursor.insert" = { bg = "accent" }
49 -"ui.cursor.select" = { fg = "accent", bg = "accent" }
50 -"ui.cursor.match" = { fg = "important_global", modifiers = ["slow_blink"] }
52 -"ui.selection" = { fg = "minor", bg = "ui_minor" }
53 -"ui.selection.primary" = { fg = "normal", bg = "ui_selection" }
55 -"ui.linenr" = { fg = "ui_minor" }
56 -"ui.linenr.selected" = { fg = "ui_normal" }
58 -"ui.statusline" = { fg = "ui_minor", bg = "ui_backdrop" }
59 -"ui.statusline.inactive" = { fg = "ui_minor" }
61 -"ui.popup" = { fg = "ui_fg_debug", bg = "ui_bg_debug" }
62 -# the special popup on SPACE
63 -"ui.popup.info" = { fg = "ui_normal", bg = "ui_backdrop" }
65 -# space between buffers
66 -"ui.window" = { fg = "ui_minor", bg = "ui_backdrop" }
68 -# help text box above command input
69 -"ui.help" = { fg = "ui_important", bg = "ui_backdrop" }
71 -"ui.text" = { fg = "normal" }
72 -# focused item in file picker
73 -"ui.text.focus" = { fg = "ui_important" }
74 -# text in SPACE popup
75 -"ui.text.info" = { fg = "ui_normal" }
77 -"ui.menu.selected" = { fg = "ui_important", modifiers = ["underlined"] }
79 -# selected line in buffer picker
80 -"ui.highlight" = { bg = "ui_cursor" }
82 -"ui.virtual.ruler" = { bg = "ui_backdrop" }
83 -"ui.virtual.whitespace" = { fg = "minor_backdrop" }
85 -"diagnostic" = { fg = "ui_normal", modifiers = ["underlined"] }
87 -"warning" = { bg = "warning" }
88 -"error" = { bg = "error", modifiers = ["rapid_blink"] }
89 -"info" = { bg = "info" }
90 -"hint" = { fg = "info", modifiers = ["dim"] }
92 -[palette]
93 -normal = "#c9c9c9"
94 -accent = "#8BABA5"
95 -backdrop = "#131313"
96 -important_local = "#f0f0f0"
97 -important_global = "#ffffff"
98 -minor = "#818181"
99 -minor_backdrop = "#0B2B25"
101 -ui_normal = "#31ae99"
102 -ui_selection = "#287F70"
103 -ui_cursor = "#56968C"
104 -ui_cursor_insert = "#2F77AE"
105 -ui_cursor_select = "#992FAE"
106 -ui_backdrop = "#18574C"
107 -ui_important = "#aefeff"
108 -ui_minor = "#113131"
110 -error = "#A21300"
111 -warning = "#A2A213"
112 -info = "#13A2A2"
114 -ui_fg_debug = "#ffffff"
115 -ui_bg_debug = "#000000"
117 -debug = "#FF2EDD"

nushell/config.nu

Modified
8 8 use svn.nu *
9 9 use openssl.nu *
10 10 use pacnew.nu
11 +use syncthing.nu
12 13 # CUSTOM COMPLETIONS
13 14 use svn-completions.nu *

nushell/env.nu

Modified
1 1 # GLOBAL VARIABLES
3 -let-env WIN32? = ( $nu.os-info.name =~ "windows" )
3 +let-env WIN32 = ( $nu.os-info.name =~ "windows" )
4 4 let-env NURC_DIR = ( $nu.config-path | path expand | path dirname )
5 5 let-env DOTFILES = ( $env.NURC_DIR | path join ".." | path expand )
6 -let-env WORKSPACE = if $env.WIN32? { "W:/" } else { "~/Workspace" | path expand }
7 -let-env NOTES = if $env.WIN32? { "N:/" } else { "~/Notes" | path expand }
6 +let-env WORKSPACE = if $env.WIN32 { "W:/" } else { "~/Workspace" | path expand }
7 +let-env NOTES = if $env.WIN32 { "N:/" } else { "~/Notes" | path expand }
9 9 # theme for ls and other programs, that use LS_COLORS
10 -let-env LS_COLORS = (vivid generate nord)
10 +let-env LS_COLORS = ( do -i { vivid generate nord } )
12 12 # Specifies how environment variables are:
13 13 # - converted from a string to a value on Nushell startup (from_string)
16 16 let-env ENV_CONVERSIONS = {
17 17 "PATH": {
18 18 from_string: { |s| $s | split row (char esep) }
19 - to_string: { |v| $v | str collect (char esep) }
19 + to_string: { |v| $v | str join (char esep) }
21 21 "Path": {
22 22 from_string: { |s| $s | split row (char esep) }
23 - to_string: { |v| $v | str collect (char esep) }
23 + to_string: { |v| $v | str join (char esep) }

nushell/modules/aliases.nu

Modified
9 9 # TODO: HOST SPECIFIC ALIASES
10 10 # I do not see a way right now the have different aliases per host with nu.
12 +# update windows user environment variables
13 +alias ue = let-env Path = (do $env.ENV_CONVERSIONS.Path.from_string (powershell -C '[System.Environment]::GetEnvironmentVariable('PATH', [System.EnvironmentVariableTarget]::User)') | append $env.Path | flatten | uniq)
12 15 # CUSTOM LITTLE JAVA COMMANDS
13 -export alias aes = java (build-string $env.DOTFILES /tools/ aes.java)
14 -export alias download = java (build-string $env.DOTFILES /tools/ download.java)
15 -export alias download_jar = java (build-string $env.DOTFILES /tools/ download_jar.java)
16 +export alias aes = java ($env.DOTFILES + /tools/ + aes.java)
17 +export alias download = java ($env.DOTFILES + /tools/ + download.java)
18 +export alias download_jar = java ($env.DOTFILES + /tools/ + download_jar.java)
17 20 # systemd
18 21 export alias userctl = systemctl --user
20 -# nushell
21 -alias now = (date now)

nushell/modules/git.nu

Modified
35 35 echo (build-string "[" ID : $id "]" " key with title " (ansi gb) $title (ansi reset) " was created at " (ansi yi) $created_at (ansi reset) "." (char newline) )
36 36 echo (build-string (ansi wu) "PUBLIC SSH KEY:" (ansi reset))
37 37 echo (char newline)
38 - echo ($key | ansi gradient --fgstart 0xaefe9f --fgend 0xfefefe)
38 + echo ($key | ansi gradient --fgstart "0xaefe9f" --fgend "0xfefefe")
39 39 echo (char newline)
41 41 } else {
48 48 export def glog [
49 49 ...rest: string # Extra arguments to git log
51 - git log --pretty=%h»¦«%s»¦«%aN»¦«%aE»¦«%aD -n 25 $rest | lines | split column "»¦«" commit subject name email date | update date { get date | into datetime} | sort-by date
51 + git log --pretty=%h»¦«%s»¦«%aN»¦«%aE»¦«%aD -n 25 $rest | lines | split column "»¦«" commit subject name email date | update date { || get date | into datetime } | sort-by date
54 54 # Show the effective configuration of git

nushell/modules/os.nu

Modified
4 4 # Opens the given resource in the operating systems preferred application.
5 5 export def start [
6 6 ...rest: string # Paths or URLs the OS should open for you.
8 - if $env.WIN32? {
8 + if $env.WIN32 {
9 9 $rest | each { |thing| ^start $thing}
10 10 } else {
11 11 $rest | each { |thing| ^xdg-open $thing }

nushell/modules/prompt.nu

Modified
4 4 # Map of paths to icons.
5 5 # These will be used to replace certain path segments in the prompt for example.
6 6 # Order these paths for precedence.
7 7 def icons [] {
9 9 [ path icon ];
10 - [ "/home/oli/Notes" (char -u "1f4d3") ]
11 - [ "C:\\Users\\okr\\Notes" (char -u "1f4d3") ]
12 - [ "/home/oli/Workspace" (char -u "1f4bb") ]
13 - [ "C:\\Users\\okr\\Workspaces" (char -u "1f4bb") ]
14 - [ "/home/oli" (char nf_house2) ]
15 - [ "C:\\Users\\okr" (char nf_house2) ]
11 + [ "/home/oli/Notes" (char -u "03C0") ]
12 + [ "/home/bugabinga/Notes" (char -u "03C0") ]
13 + [ "C:\\Users\\okr\\Notizen" (char -u "03C0") ]
15 + [ "/home/oli/Workspace" (char -u "03BB") ]
16 + [ "/home/bugabinga/Workspace" (char -u "03BB") ]
17 + [ "C:\\Users\\okr\\Workspaces" (char -u "03BB") ]
19 + [ "/home/oli" (char home) ]
20 + [ "/home/bugabinga" (char home) ]
21 + [ "C:\\Users\\okr" (char home) ]
23 29 let icon = if (icons | any { |icon| $icon.path == $pwd } ) { ( icons | where path == $pwd | get icon.0 ) } else { $"(char nf_folder1)" }
24 30 # Some terminals freeze, if they do not support this OSC
25 31 if ($env | get -i TERM_PROGRAM) == WezTerm {
26 - echo ([ (ansi title) $icon " " ( $pwd | path basename ) (ansi reset) ] | str collect)
32 + echo ([ (ansi title) $icon " " ( $pwd | path basename ) (ansi reset) ] | str join)
32 38 let pwd = ($env.PWD | path expand)
34 40 let svn_relative_cmd = ( do --ignore-errors { ^svn info --show-item relative-url --no-newline $pwd | complete } )
35 - let svn_relative_path = if ($svn_relative_cmd.exit_code == 0) { $" 🐢 (char nf_branch) ($svn_relative_cmd.stdout)" }
41 + let svn_relative_path = if ( (not ($svn_relative_cmd | is-empty)) and ($svn_relative_cmd.exit_code == 0)) { $" 🐢 (char nf_branch) ($svn_relative_cmd.stdout)" }
37 - let git_status = ( gstat )
38 - let git_branch = if ( $git_status.branch != "no_branch" ) { $" (char nf_git) (char nf_branch) ($git_status.branch)" }
43 + let git_status = ( do --ignore-errors { gstat } )
44 + let git_branch = if ( ( not ($git_status | is-empty)) and ($git_status.branch != "no_branch") ) { $" (char nf_git) (char nf_branch) ($git_status.branch)" }
41 47 $svn_relative_path
42 48 $git_branch
43 - ] | str collect
49 + ] | str join
46 52 def create_left_prompt [] {
49 55 # normalize path
50 56 let pwd = ($env.PWD | path expand)
51 - let pwd = (icons | reduce --fold $pwd { |item, accumulator| $accumulator | str replace --string $item.path $item.icon })
57 + let pwd = ( (icons) | reduce --fold $pwd { |item, accumulator| $accumulator | str replace --string $item.path $item.icon })
52 58 let truncate_level = 5
53 59 let truncate_symbol = $"…(char path_sep)"
54 60 let path_segment = if ($pwd | path split | length) >= $truncate_level { ($pwd | path dirname --num-levels 2 --replace $truncate_symbol ) } else { $pwd }
56 - let vcs_segment = get_vcs_path
62 + let vcs_segment = (get_vcs_path)
59 65 (ansi dark_gray)
62 68 (ansi green)
63 69 $vcs_segment
64 70 (ansi reset)
65 - ] | str collect
71 + ] | str join
68 74 def create_right_prompt [] {
69 75 let time_segment = ([
70 76 (date now | date format '%d.%m %R')
71 - ] | str collect)
77 + ] | str join)
73 79 let command_status_segment = if $env.LAST_EXIT_CODE == 0 { $" (char -u '2713') " } else { $"(ansi red) (char failed) (ansi reset)" }
74 80 let command_duration_segment = if ( $env.CMD_DURATION_MS | into int) > 0 { $"($env.CMD_DURATION_MS)ms" | into duration }
83 89 (ansi dark_gray)
84 90 $time_segment
85 91 (ansi reset)
86 - ] | str collect
92 + ] | str join
89 95 export-env {
90 96 # Use nushell functions to define your right and left prompt
91 - let-env PROMPT_COMMAND = { create_left_prompt }
92 - let-env PROMPT_COMMAND_RIGHT = { create_right_prompt }
97 + let-env PROMPT_COMMAND = { || create_left_prompt }
98 + let-env PROMPT_COMMAND_RIGHT = { || create_right_prompt }
94 100 # The prompt indicators are environmental variables that represent
95 101 # the state of the prompt
96 - let-env PROMPT_INDICATOR = $"(ansi purple) (char prompt) (ansi reset)"
97 - let-env PROMPT_INDICATOR_VI_INSERT = $"(ansi purple) (char pipe) (ansi reset)"
98 - let-env PROMPT_INDICATOR_VI_NORMAL = $"(ansi purple) (char prompt) (ansi reset)"
99 - let-env PROMPT_MULTILINE_INDICATOR = $"(ansi purple) (char prompt)(char prompt) (ansi reset)"
102 + let-env PROMPT_INDICATOR = $"(ansi green) (char prompt) (ansi reset)"
103 + let-env PROMPT_INDICATOR_VI_INSERT = $"(ansi magenta) (char pipe) (ansi reset)"
104 + let-env PROMPT_INDICATOR_VI_NORMAL = $"(ansi magenta) (char prompt) (ansi reset)"
105 + let-env PROMPT_MULTILINE_INDICATOR = $"(ansi magenta) (char prompt)(char prompt) (ansi reset)"

nushell/modules/syncthing.nu

Added
new file mode 100644
1 +export def "conflicts list" [] {
2 + fd --hidden --no-ignore sync-conflict $env.HOME |
3 + lines |
4 + filter { |path| not ($path =~ "/Trash/") }
5 +}
7 +export def "conflicts merge" [] {
8 + (conflicts list) |
9 + each { |conflict|
10 + merge ( to_original $conflict ) $conflict
11 + let input = ( input $"Merge successful? \((ansi pb)Y(ansi reset)/n\) \n" )
12 + let sanitize = ( $input | str trim | str downcase | str substring 0..1 )
13 + if ($sanitize | is-empty) or $sanitize == 'y' {
14 + rm --verbose --interactive $conflict
15 + } else {
16 + $conflict
17 + }
18 + }
21 +export def "conflicts diff" [] {
22 + (conflicts list) |
23 + each { |conflict|
24 + diff ( to_original $conflict ) $conflict
25 + }
28 +def parse-sync-conflict [] {
29 + parse -r '(?<filename>.*)\.sync-conflict-(?<date>.\d+)-(?<time>.\d+)-(?<id>\w+)\.?(?<extension>.*)?'
32 +def to_original [ file: path ] {
33 + let conflict = ( $file | parse-sync-conflict )
34 + mut filename = ($conflict | get filename.0)
35 + let extension = ($conflict | get extension.0)
36 + if not ($extension | is-empty) {
37 + $filename = $filename + '.' + $extension
38 + }
39 + $filename
42 +def diff [ a: path, b: path ] {
43 + print $"diffing ($a) and ($b)"
44 + ^difft $a $b
46 +def merge [ a: path, b: path ] {
47 + meld $a $b

nushell/modules/table.nu

Modified
8 8 # Flattens a table into a string separated by a single space character.
9 -export def to-string [] { flatten | into string | str collect ' ' }
9 +export def to-string [] { flatten | into string | str join ' ' }

nushell/modules/zoxide.nu

Modified
10 10 let-env config = ($env | default {} config).config
11 11 let-env config = ($env.config | default {} hooks)
12 12 let-env config = ($env.config | update hooks ($env.config.hooks | default [] pre_prompt))
13 - let-env config = ($env.config | update hooks.pre_prompt ($env.config.hooks.pre_prompt | append {
13 + let-env config = ($env.config | update hooks.pre_prompt ($env.config.hooks.pre_prompt | append { ||
14 14 zoxide add -- $env.PWD

pop-os.symlinks

Modified
4 4 git/gitconfig
5 5 ~/.config/git/config
7 7 git/gitconfig.linux
8 8 ~/.config/git/.gitconfig.include
10 +tools/git-info
11 +~/.local/bin/git-info
10 13 cargo/config.toml
11 14 ~/.cargo/config.toml
13 -nushell
14 -~/.config/nushell
16 +bat/config
17 +~/.config/bat/config
19 +nushell/completions
20 +~/.config/nushell/completions
22 +nushell/config.nu
23 +~/.config/nushell/config.nu
25 +nushell/env.nu
26 +~/.config/nushell/env.nu
28 +nushell/modules
29 +~/.config/nushell/modules
31 +nushell/plugin.nu
32 +~/.config/nushell/plugin.nu
16 34 stackoverflow/so
17 35 ~/.config/so
22 40 wezterm
23 41 ~/.config/wezterm
43 +wezterm/wezterm.service
44 +~/.config/systemd/user/wezterm.service
25 46 helix/config.toml
26 47 ~/.config/helix/config.toml
49 +helix/languages.toml
50 +~/.config/helix/languages.toml
28 52 helix/themes
29 53 ~/.config/helix/themes
55 +helix/systemd/helix-dark-mode.service
56 +~/.config/systemd/user/helix-dark-mode.service
58 +xplr
59 +~/.config/xplr
31 61 ssh/config
32 62 ~/.ssh/config
34 64 neovim
35 65 ~/.config/nvim
67 +river
68 +~/.config/river

ssh/config

Modified
3 3 # SSH client configuration
4 4 # defines bookmarks/templates for hosts and options to quickly connect to known hosts
7 7 Host box
8 - HostName box.bugabinga.net
9 - IdentityFile ~/.ssh/box_do.key
8 + HostName 46.101.206.216
9 + IdentityFile ~/.ssh/box.bugabinga.net.key
11 11 Host github.com
12 12 HostName github.com
12 12 IdentityFile ~/.ssh/github.key
14 14 Host codeberg.org
15 - HostName codeberg.org
16 - User git
17 - IdentityFile ~/.ssh/codeberg.key
15 + HostName codeberg.org
16 + User git
17 + IdentityFile ~/.ssh/codeberg.key
20 20 # catch-all pattern

tools/cargo-tools.nu

Modified
28 28 [ "diskonaut" "diskonaut" [] ]
29 29 [ "menyoki" "menyoki" [] ]
30 30 [ "zoxide" "zoxide" [] ]
31 + [ "difftastic" "difft" []]
31 32 [ "grex" "grex" [] ]
32 33 [ "xh" "xh" [] ]
33 34 [ "comrak" "comrak" [] ]
53 54 def coreutils-features [] {
54 - if $env.WIN32? {
55 + if $nu.os-info.family == 'windows' {
55 56 [ "--features" "windows" ]
56 57 } else {
57 58 [ "--features" "unix" ]
61 62 def so-features [] {
62 - if $env.WIN32? {
63 + if $nu.os-info.family == 'windows' {
63 64 [ "--no-default-features" "--features" "windows" ]
64 65 } else {
69 -def install-helix-editor [] {
70 - cd $env.WORKSPACE
71 - if ( not ($env.WORKSPACE | path join "helix/.git" | path exists) ) {
72 - git clone https://github.com/helix-editor/helix
73 - }
74 - cd helix
75 - git fetch
76 - # check if fetch actually downloaded anything new
77 - # if (not ((git rev-parse HEAD) == (git rev-parse @{u}))) {
78 - # topgrade has already updated the repo by this point, so that we never hit this case.
79 - # needs alternative idea
80 - git pull
81 - let toolchain = (if $nu.os-info.family == "windows" {"+stable-msvc"} else {"+stable"})
82 - cargo $toolchain install --path helix-term --profile opt
83 - hx --grammar fetch | ignore
84 - hx --grammar build | ignore
85 - # }
86 -}
88 70 # install all my favorite crate, only if they are not already in PATH.
89 71 def main [] {
90 72 $cargo_crates | each { | crate |
95 77 echo $"($crate.name) already installed"
98 - install-helix-editor

tools/git-info

Added
new file mode 100755
1 +#!/bin/sh
2 +#
3 +# git-info - shows information about a Git repository a la `svn info'
4 +#
5 +# How to use:
6 +# $ git info
7 +# $ git info ~/src/somewhere/somefile
8 +# $ git info some/relative/file_or_directory
9 +# $ git info ~/repos/something.git
11 +# Copyright (c) 2009-2022 Akinori MUSHA
13 +# All rights reserved.
15 +# Redistribution and use in source and binary forms, with or without
16 +# modification, are permitted provided that the following conditions
17 +# are met:
18 +# 1. Redistributions of source code must retain the above copyright
19 +# notice, this list of conditions and the following disclaimer.
20 +# 2. Redistributions in binary form must reproduce the above copyright
21 +# notice, this list of conditions and the following disclaimer in the
22 +# documentation and/or other materials provided with the distribution.
24 +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
25 +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
26 +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
27 +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
28 +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
29 +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
30 +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
31 +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
32 +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
33 +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
34 +# SUCH DAMAGE.
37 +COLOR=
39 +main () {
40 + local opt
41 + local OPTS_SPEC="\
42 +$0 [<options>] [<path>]
44 +$0 shows information about a Git repository.
45 +--
46 +h,help show the help
47 +color?when show colored output (always|never|auto)
49 + eval "$(echo "$OPTS_SPEC" | git rev-parse --parseopt --stuck-long -- "$@" || echo exit $?)"
51 + while [ $# -gt 0 ]; do
52 + opt="$1"
53 + shift
55 + case "$opt" in
56 + --color)
57 + COLOR=always
58 + ;;
59 + --color\=*)
60 + COLOR="${opt#*=}"
61 + ;;
62 + --)
63 + break
64 + ;;
65 + *)
66 + die "Unexpected option: $opt"
67 + ;;
68 + esac
69 + done
71 + initialize_colors
73 + case "$#" in
74 + 1)
75 + ;;
76 + 0)
77 + if [ -n "$GIT_DIR" ]; then
78 + set -- "$GIT_DIR"
79 + else
80 + set -- .
81 + fi
82 + ;;
83 + *)
84 + die "Too many arguments"
85 + ;;
86 + esac
88 + git_info "$1"
91 +initialize_colors () {
92 + if [ -z "$COLOR" ]; then
93 + if git config --get-colorbool color.info; then
94 + COLOR=always
95 + else
96 + COLOR=never
97 + fi
98 + fi
100 + case "$COLOR" in
101 + always|never)
102 + COLOR_BRANCH=$COLOR
103 + ;;
104 + auto)
105 + if git config --get-colorbool color.branch; then
106 + COLOR_BRANCH=always
107 + else
108 + COLOR_BRANCH=never
109 + fi
110 + ;;
111 + *)
112 + die "option \`color' expects \"always\", \"auto\", or \"never\""
113 + ;;
114 + esac
116 + if [ "$COLOR" = always ]; then
117 + REMOTE_COLOR="$(get_color color.info.remote color.branch.remote red)"
118 + LOCAL_COLOR="$(get_color color.info.local color.branch.local green)"
119 + PATH_COLOR="$(get_color color.info.path '' 'bold')"
120 + REPOSITORY_COLOR="$(get_color color.info.repository '' 'bold')"
121 + ID_COLOR="$(get_color color.info.id '' 'yellow')"
122 + RESET_COLOR=$(printf "\033[m")
123 + else
124 + REMOTE_COLOR=
125 + LOCAL_COLOR=
126 + PATH_COLOR=
127 + REPOSITORY_COLOR=
128 + ID_COLOR=
129 + RESET_COLOR=
130 + fi
133 +get_color () {
134 + local key1="$1" key2="$2" fb="$3"
135 + local color="$(git config --get-color "$key1" '')"
136 + case "$color" in
137 + ''|'')
138 + git config --get-color "$key2" "$fb"
139 + ;;
140 + *)
141 + printf '%s' "$color"
142 + ;;
143 + esac
146 +git_info () {
147 + local path="$1" dir relpath root git_dir
149 + if [ -d "$path" ]; then
150 + dir="$(cd -P "$path" && pwd)" || die "$path: Cannot cd to the directory"
151 + case "$path" in
152 + *.git)
153 + git_dir="$dir"
154 + ;;
155 + esac
156 + elif [ -f "$path" ]; then
157 + dir="$(dirname "$path")"
158 + dir="$(cd -P "$dir" && pwd)" || die "$dir: Cannot cd to the directory"
159 + relpath="$(basename "$path")"
160 + else
161 + die "$path: No such file or directory"
162 + fi
164 + if [ -n "$git_dir" ]; then
165 + dir=
166 + relpath=
167 + elif case "$dir" in ?*.git) [ -d "$dir/objects" -a -d "$dir/refs" ] ;; *) false ;; esac; then
168 + git_dir="$dir"
169 + relpath=
170 + else
171 + root="$(
172 + cd "$dir" || exit 1
173 + while [ ! -e .git ]; do
174 + [ "$(pwd)" = / ] && exit 1
175 + cd ..
176 + done
177 + pwd
178 + )" || die "Not a git repository."
179 + git_dir="$root/.git"
180 + if [ "$dir" = "$root" ]; then
181 + relpath=.
182 + elif [ -n "$relpath" ]; then
183 + relpath="${dir#"$root/"}/$relpath"
184 + else
185 + relpath="${dir#"$root/"}"
186 + fi
187 + fi
189 + set -- "$git_dir"
190 + if [ -n "$relpath" ]; then
191 + set -- "$@" "$relpath"
192 + fi
194 + do_git_info "$@"
197 +do_git_info () {
198 + local git_dir="$1" relpath="$2" root line field color reset
200 + shift
202 + echo "Repository Path: $PATH_COLOR$git_dir$RESET_COLOR"
204 + if [ $# -gt 0 ]; then
205 + root="$(dirname "$git_dir")"
206 + if [ "$relpath" = . ]; then
207 + echo "Path: $PATH_COLOR$root$RESET_COLOR"
208 + else
209 + echo "Path: $PATH_COLOR$root/$relpath$RESET_COLOR"
210 + fi
211 + fi
213 + maketemp
215 + GIT_DIR="$git_dir" git remote -v > "$TEMPFILE"
216 + if [ -s "$TEMPFILE" ]; then
217 + echo "Remote Repositories:"
218 + sed -e "s/^\([^ ]\{1,\}\)\([ ]\{1,\}\)\([^ ]\{1,\}\)/$REMOTE_COLOR\1$RESET_COLOR\2$REPOSITORY_COLOR\3$RESET_COLOR/" \
219 + -e 's/^/ /' \
220 + "$TEMPFILE"
221 + fi
223 + GIT_DIR="$git_dir" git branch -r --color=$COLOR_BRANCH > "$TEMPFILE"
224 + if [ -s "$TEMPFILE" ]; then
225 + echo "Remote Branches:"
226 + sed -e "s/\([ ]\{1,\}->[ ]\{1,\}\)\([^ ]\{1,\}\)/\1$REMOTE_COLOR\2$RESET_COLOR/" \
227 + -e 's/^ */ /' "$TEMPFILE"
228 + fi
230 + GIT_DIR="$git_dir" git branch --color=$COLOR_BRANCH > "$TEMPFILE"
231 + if [ -s "$TEMPFILE" ]; then
232 + echo "Local Branches:"
233 + sed 's/^/ /' "$TEMPFILE"
234 + fi
236 + echo "Repository Configuration:"
237 + GIT_DIR="$git_dir" git config --local --list | sort | {
238 + prev_section=
239 + prev_subsection=
240 + while read line; do
241 + case "$line" in
242 + (*=*)
243 + lhs=$(expr "$line" : '\([^=]\{1,\}\)')
244 + rhs=$(expr "$line" : '[^=]\{1,\}=\(.*\)')
245 + case "$lhs" in
246 + (?*.?*.?*)
247 + section=$(expr "$lhs" : '\([^.]\{1,\}\)')
248 + subsection=$(expr "$lhs" : '[^.]\{1,\}\.\(.\{1,\}\)\.')
249 + key=$(expr "$lhs" : '[^.]\{1,\}\..\{1,\}\.\([^.]\{0,\}\)$')
250 + if [ "$section" != "$prev_section" -o "$subsection" != "$prev_subsection" ]; then
251 + prev_section=$section
252 + prev_subsection=$subsection
253 + case "$section" in
254 + (remote)
255 + subsection=$REMOTE_COLOR$subsection$RESET_COLOR
256 + ;;
257 + (branch)
258 + subsection=$LOCAL_COLOR$subsection$RESET_COLOR
259 + esac
260 + printf "\t[%s \"%s\"]\n" "$section" "$subsection"
261 + fi
262 + case "$section" in
263 + (remote)
264 + if [ "$key" = url ]; then
265 + rhs=$REPOSITORY_COLOR$rhs$RESET_COLOR
266 + fi
267 + ;;
268 + (branch)
269 + if [ "$key" = remote ]; then
270 + rhs=$REMOTE_COLOR$rhs$RESET_COLOR
271 + fi
272 + esac
273 + printf "\t\t%s = %s\n" "$key" "$rhs"
274 + ;;
275 + (?*.?*)
276 + section=$(expr "$lhs" : '\([^.]\{1,\}\)')
277 + key=$(expr "$lhs" : '[^.]\{1,\}\.\([^.]\{1,\}\)$')
278 + if [ "$section" != "$prev_section" -o -n "$prev_subsection" ]; then
279 + prev_section=$section
280 + prev_subsection=
281 + printf "\t[%s]\n" "$section"
282 + fi
283 + printf "\t\t$key = $rhs\n"
284 + ;;
285 + (*)
286 + esac
287 + esac
288 + done
291 + (cd "$root" && GIT_DIR="$git_dir" git log --max-count=1 "$@") | {
292 + while read -r field line; do
293 + color=
294 + reset=
295 + case "$field" in
296 + commit)
297 + field='Commit ID:'
298 + color="$ID_COLOR"
299 + reset="$RESET_COLOR"
300 + ;;
301 + *:)
302 + ;;
303 + '')
304 + break
305 + ;;
306 + esac
307 + echo "Last Changed $field $color$line$reset"
308 + done
309 + cat > "$TEMPFILE"
311 + echo "Last Changed Log:"
312 + sed 's/^ / /' "$TEMPFILE"
314 + finalize
317 +die () {
318 + [ "$#" -gt 0 ] && echo "$0: $@" >&2
319 + finalize
320 + exit 1
323 +TEMPFILE=
325 +maketemp () {
326 + if [ -z "$TEMPFILE" ]; then
327 + TEMPFILE="$(mktemp /tmp/git-info.XXXXXX)" || die
328 + trap "finalize; exit 130" 1 2 3 15
329 + fi
332 +finalize () {
333 + if [ -n "$TEMPFILE" ]; then
334 + rm -f "$TEMPFILE"
335 + fi
338 +main "$@"

tools/vivid_themes.nu

Added
new file mode 100755
1 +#!/usr/bin/env nu
3 +def main [] {
4 + (vivid themes) |
5 + lines |
6 + str trim |
7 + each { |theme|
8 + print $"theme: (ansi black_bold)($theme)(ansi reset)"
9 + with-env { LS_COLORS: (vivid generate $theme) } {
10 + exa
11 + print "\n"
12 + }
13 + }

wezterm/bugabinga/dark_mode.lua

Added
new file mode 100644
1 +local wez = require 'wezterm'
3 +-- wezterm.gui is not available to the mux server, so take care to
4 +-- do something reasonable when this config is evaluated by the mux
5 +local get_appearance = function()
6 + if wez.gui then
7 + return wez.gui.get_appearance()
8 + end
9 + return 'Dark'
10 +end
12 +local scheme_for_appearance = function(appearance)
13 + if appearance:find 'Dark' then
14 + return 'nugu-dark'
15 + else
16 + return 'nugu-light'
17 + end
18 +end
20 +wez.on('window-config-reloaded', function(window)
21 + local overrides = window:get_config_overrides() or {}
22 + local appearance = window:get_appearance()
23 + local scheme = scheme_for_appearance(appearance)
24 + if overrides.color_scheme ~= scheme then
25 + overrides.color_scheme = scheme
26 + window:set_config_overrides(overrides)
27 + end
28 +end)
30 +return scheme_for_appearance(get_appearance())

wezterm/bugabinga/key_binds.lua

Added
new file mode 100644
1 +local wez = require 'wezterm'
2 +local leader = { key = 'raw:255'}
4 +local resize_pane_mode = 'ﭕ Resize Pane Mode'
5 +local activate_pane_mode = ' Activate Pane Mode'
6 +local font_size_mode = ' Change Font Size Mode'
8 +local keys = {
9 + -- Modes
10 + {
11 + key = 'r',
12 + mods = 'LEADER',
13 + action = wez.action.ActivateKeyTable {
14 + name = resize_pane_mode,
15 + one_shot = false,
16 + },
17 + },
18 + {
19 + key = 'a',
20 + mods = 'LEADER',
21 + action = wez.action.PaneSelect,
22 + },
23 + {
24 + key = 'f',
25 + mods = 'LEADER',
26 + action = wez.action.TogglePaneZoomState,
27 + },
28 + -- global actions
29 + {
30 + key = 'F2',
31 + action = wez.action.SwitchWorkspaceRelative(-1),
32 + },
33 + {
34 + key = 'F3',
35 + action = wez.action.SwitchWorkspaceRelative(1),
36 + },
37 + {
38 + key = 'F5',
39 + action = wez.action.ReloadConfiguration,
40 + },
41 + {
42 + key = 'F11',
43 + action = wez.action.ToggleFullScreen,
44 + },
45 + {
46 + key = 'F12',
47 + action = wez.action.ShowDebugOverlay,
48 + },
49 + -- change font size
50 + {
51 + key = '0',
52 + mods = 'LEADER',
53 + action = wez.action.ActivateKeyTable {
54 + name = font_size_mode,
55 + one_shot = false,
56 + },
57 + },
58 + -- open unicode/emoji picker
59 + {
60 + key = 'u',
61 + mods = 'LEADER',
62 + action = wez.action.CharSelect {
63 + copy_on_select = true,
64 + copy_to = 'ClipboardAndPrimarySelection'
65 + },
66 + },
67 + -- Copy and Paste
68 + {
69 + key = 'c',
70 + mods = 'CTRL|SHIFT',
71 + action = wez.action.CopyTo 'Clipboard',
72 + },
73 + {
74 + key = 'v',
75 + mods = 'CTRL|SHIFT',
76 + action = wez.action.PasteFrom 'Clipboard',
77 + },
78 + -- Splitting Panes
79 + {
80 + key = 'v',
81 + mods = 'LEADER',
82 + action = wez.action.SplitHorizontal { domain = 'CurrentPaneDomain' },
83 + },
84 + {
85 + key = 'h',
86 + mods = 'LEADER',
87 + action = wez.action.SplitVertical { domain = 'CurrentPaneDomain' },
88 + },
89 + -- Tabs
90 + {
91 + key = 't',
92 + mods = 'LEADER',
93 + action = wez.action.SpawnTab 'CurrentPaneDomain',
94 + },
95 + {
96 + key = 'w',
97 + mods = 'LEADER',
98 + action = wez.action.CloseCurrentPane { confirm = true },
99 + },
101 + key = 'Tab',
102 + mods = 'LEADER|CTRL',
103 + action = wez.action.ActivateTabRelative(1),
104 + },
106 + key = 'Tab',
107 + mods = 'LEADER|SHIFT',
108 + action = wez.action.ActivateTabRelative(-1),
109 + },
110 + -- Search all Actions
112 + key = 'p',
113 + mods = 'LEADER',
114 + action = wez.action.ActivateCommandPalette,
115 + },
116 + -- Quit
118 + key = 'q',
119 + mods = 'LEADER',
120 + action = wez.action.QuitApplication,
121 + },
123 +-- Navigate Tabs by LEADER+n
124 +for i = 1, 8 do
125 + -- CTRL+ALT + number to activate that tab
126 + table.insert(keys, {
127 + key = tostring(i),
128 + mods = 'LEADER',
129 + action = wez.action.ActivateTab(i - 1),
130 + })
131 +end
133 +local key_tables = {
134 + [resize_pane_mode] = {
135 + { key = 'LeftArrow', action = wez.action.AdjustPaneSize { 'Left', 1 } },
136 + { key = 'h', action = wez.action.AdjustPaneSize { 'Left', 1 } },
138 + { key = 'RightArrow', action = wez.action.AdjustPaneSize { 'Right', 1 } },
139 + { key = 'l', action = wez.action.AdjustPaneSize { 'Right', 1 } },
141 + { key = 'UpArrow', action = wez.action.AdjustPaneSize { 'Up', 1 } },
142 + { key = 'k', action = wez.action.AdjustPaneSize { 'Up', 1 } },
144 + { key = 'DownArrow', action = wez.action.AdjustPaneSize { 'Down', 1 } },
145 + { key = 'j', action = wez.action.AdjustPaneSize { 'Down', 1 } },
147 + -- Cancel the mode
148 + { key = 'Escape', action = 'PopKeyTable' },
149 + { key = 'Enter', action = 'PopKeyTable' },
150 + },
151 + [font_size_mode] = {
152 + { key = '+', action = wez.action.IncreaseFontSize },
153 + { key = '-', action = wez.action.DecreaseFontSize },
154 + { key = '=', action = wez.action.ResetFontSize },
156 + { key = 'Escape', action = 'PopKeyTable' },
157 + },
160 +return {
161 + leader = leader,
162 + keys = keys,
163 + key_tables = key_tables,

wezterm/bugabinga/nugu.lua

Modified
1 1 return {
2 - ['nugu-dark'] = {
2 + ['nugu-dark'] = {
3 3 -- The default text color
4 - foreground = '#c9c9c9',
4 + foreground = '#cfcfcf',
5 5 -- The default background color
6 6 background = '#131313',
8 8 -- Overrides the cell background color when the current cell is occupied by the
9 9 -- cursor and the cursor style is set to Block
10 - cursor_bg = '#814eaa',
10 + cursor_bg = '#7a067a',
11 11 -- Overrides the text color when the current cell is occupied by the cursor
12 - cursor_fg = '#e0e0e0',
12 + cursor_fg = '#5f368d',
13 13 -- Specifies the border color of the cursor when the cursor style is set to Block,
14 14 -- or the color of the vertical or horizontal bar when the cursor style is set to
15 15 -- Bar or Underline.
16 - cursor_border = '#8BABA5',
16 + cursor_border = '#7a067a',
18 18 -- the foreground color of selected text
19 - selection_fg = '#fefefe',
19 + selection_fg = '#cfcfcf',
20 20 -- the background color of selected text
21 - selection_bg = '#8BABA5',
21 + selection_bg = '#4c2b72',
23 - -- The color of the scrollbar "thumb"; the portion that represents the current viewport
24 - scrollbar_thumb = '#287F70',
23 + -- The color of the scrollbar 'thumb'; the portion that represents the current viewport
24 + scrollbar_thumb = '#121212',
26 26 -- The color of the split lines between panes
27 - split = '#287F70',
27 + split = '#5f368d',
29 29 ansi = {
30 - '#113131', -- black
31 - '#A21300', -- red
32 - '#56968C', -- green
33 - '#A2A213', -- yellow
34 - '#2F77AE', -- blue
35 - '#992FAE', -- magenta
36 - '#13A2A2', -- cyan
37 - '#31ae99', -- white
30 + '#5d355c',
31 + '#c41653',
32 + '#acc1a0',
33 + '#a08d7b',
34 + '#6d15c0',
35 + '#c015c0',
36 + '#929396',
37 + '#c7c7c7',
40 40 brights = {
41 - '#638787',
42 - '#e17769',
43 - '#cacaca',
44 - '#d4d48a',
45 - '#b4c5d1',
46 - '#ccb4d1',
47 - '#8ad4d4',
48 - '#b6d1cd',
41 + '#9d9d9d',
42 + '#ea4571',
43 + '#a6a78f',
44 + '#e0cfaa',
45 + '#8940ea',
46 + '#ea3fea',
47 + '#c0d5df',
48 + '#f2eef1',
51 51 -- Since: 20220319-142410-0fcdea07
52 52 -- When the IME, a dead key or a leader key are being processed and are effectively
53 53 -- holding input pending the result of input composition, change the cursor
54 54 -- to this color to give a visual cue about the compose state.
55 - compose_cursor = '#2F77AE',
56 - visual_bell = '#A21300',
55 + compose_cursor = '#788984',
56 + -- Colors for copy_mode and quick_select
57 + -- available since: 20220807-113146-c2fee766
58 + -- In copy_mode, the color of the active text is:
59 + -- 1. copy_mode_active_highlight_* if additional text was selected using the mouse
60 + -- 2. selection_* otherwise
61 + copy_mode_active_highlight_bg = { Color = '#5f368d' },
62 + copy_mode_active_highlight_fg = { Color = '#cfcfcf' },
63 + copy_mode_inactive_highlight_bg = { Color = '#121212' },
64 + copy_mode_inactive_highlight_fg = { Color = '#727272' },
66 + quick_select_label_bg = { Color = '#5f368d' },
67 + quick_select_label_fg = { Color = '#cfcfcf' },
68 + quick_select_match_bg = { Color = '#4c2b72' },
69 + quick_select_match_fg = { Color = '#cfcfcf' },
71 + tab_bar = {
72 + -- The color of the strip that goes along the top of the window
73 + -- does not apply when fancy tab bar is in use
74 + background = '#000000',
76 + -- The active tab is the one that has focus in the window
77 + active_tab = {
78 + -- The color of the background area for the tab
79 + bg_color = '#000000',
80 + -- The color of the text for the tab
81 + fg_color = '#5f368d',
83 + -- Specify whether you want 'Half', 'Normal' or 'Bold' intensity for the
84 + -- label shown for this tab.
85 + -- The default is 'Normal'
86 + intensity = 'Bold',
88 + -- Specify whether you want 'None', 'Single' or 'Double' underline for
89 + -- label shown for this tab.
90 + -- The default is 'None'
91 + underline = 'Double',
93 + -- Specify whether you want the text to be italic or not
94 + -- for this tab. The default is false.
95 + italic = false,
97 + -- Specify whether you want the text to be rendered with strikethrough
98 + -- or not for this tab. The default is false.
99 + strikethrough = false,
100 + },
102 + -- Inactive tabs are the tabs that do not have focus
103 + inactive_tab = {
104 + bg_color = '#000000',
105 + fg_color = '#e2e2e2',
106 + intensity = 'Normal',
108 + -- The same options that were listed under the `active_tab` section above
109 + -- can also be used for `inactive_tab`.
110 + },
112 + -- You can configure some alternate styling when the mouse pointer
113 + -- moves over inactive tabs
114 + inactive_tab_hover = {
115 + bg_color = '#788984',
116 + fg_color = '#e2e2e2',
117 + italic = true,
119 + -- The same options that were listed under the `active_tab` section above
120 + -- can also be used for `inactive_tab_hover`.
121 + },
123 + -- The new tab button that let you create new tabs
124 + new_tab = {
125 + bg_color = '#000000',
126 + fg_color = '#121212',
128 + -- The same options that were listed under the `active_tab` section above
129 + -- can also be used for `new_tab`.
130 + },
132 + -- You can configure some alternate styling when the mouse pointer
133 + -- moves over the new tab button
134 + new_tab_hover = {
135 + bg_color = '#788984',
136 + fg_color = '#e2e2e2',
137 + italic = true,
139 + -- The same options that were listed under the `active_tab` section above
140 + -- can also be used for `new_tab_hover`.
141 + },
142 + },
58 - ['nugu-light'] = {
144 + ['nugu-light'] = {
59 145 -- The default text color
60 - foreground = '#131313',
146 + foreground = '#494949',
61 147 -- The default background color
62 - background = '#c9c9c9',
148 + background = '#e3e3e3',
64 150 -- Overrides the cell background color when the current cell is occupied by the
65 151 -- cursor and the cursor style is set to Block
66 - cursor_bg = '#814eaa',
152 + cursor_bg = '#d43dd4',
67 153 -- Overrides the text color when the current cell is occupied by the cursor
68 - cursor_fg = '#e0e0e0',
154 + cursor_fg = '#9170b5',
69 155 -- Specifies the border color of the cursor when the cursor style is set to Block,
70 156 -- or the color of the vertical or horizontal bar when the cursor style is set to
71 157 -- Bar or Underline.
72 - cursor_border = '#8BABA5',
158 + cursor_border = '#d43dd4',
74 160 -- the foreground color of selected text
75 - selection_fg = '#fefefe',
161 + selection_fg = '#494949',
76 162 -- the background color of selected text
77 - selection_bg = '#8BABA5',
163 + selection_bg = '#ae95c8',
79 - -- The color of the scrollbar "thumb"; the portion that represents the current viewport
80 - scrollbar_thumb = '#287F70',
165 + -- The color of the scrollbar 'thumb'; the portion that represents the current viewport
166 + scrollbar_thumb = '#c9c9c9',
82 168 -- The color of the split lines between panes
83 - split = '#287F70',
169 + split = '#9170b5',
85 171 ansi = {
86 - '#113131', -- black
87 - '#A21300', -- red
88 - '#56968C', -- green
89 - '#A2A213', -- yellow
90 - '#2F77AE', -- blue
91 - '#992FAE', -- magenta
92 - '#13A2A2', -- cyan
93 - '#31ae99', -- white
172 + '#060406',
173 + '#4a081f',
174 + '#668355',
175 + '#55493d',
176 + '#280845',
177 + '#450845',
178 + '#4e4f51',
179 + '#838383',
96 182 brights = {
97 - '#638787',
98 - '#e17769',
99 - '#cacaca',
100 - '#d4d48a',
101 - '#b4c5d1',
102 - '#ccb4d1',
103 - '#8ad4d4',
104 - '#b6d1cd',
183 + '#595959',
184 + '#961134',
185 + '#60624c',
186 + '#bb9647',
187 + '#481091',
188 + '#901090',
189 + '#6599b1',
190 + '#b6a1b4',
107 193 -- Since: 20220319-142410-0fcdea07
108 194 -- When the IME, a dead key or a leader key are being processed and are effectively
109 195 -- holding input pending the result of input composition, change the cursor
110 196 -- to this color to give a visual cue about the compose state.
111 - compose_cursor = '#2F77AE',
112 - visual_bell = '#A21300',
197 + compose_cursor = '#646464',
198 + -- Colors for copy_mode and quick_select
199 + -- available since: 20220807-113146-c2fee766
200 + -- In copy_mode, the color of the active text is:
201 + -- 1. copy_mode_active_highlight_* if additional text was selected using the mouse
202 + -- 2. selection_* otherwise
203 + copy_mode_active_highlight_bg = { Color = '#9170b5' },
204 + copy_mode_active_highlight_fg = { Color = '#494949' },
205 + copy_mode_inactive_highlight_bg = { Color = '#c9c9c9' },
206 + copy_mode_inactive_highlight_fg = { Color = '#878787' },
208 + quick_select_label_bg = { Color = '#9170b5' },
209 + quick_select_label_fg = { Color = '#494949' },
210 + quick_select_match_bg = { Color = '#ae95c8' },
211 + quick_select_match_fg = { Color = '#494949' },
213 + tab_bar = {
214 + -- The color of the strip that goes along the top of the window
215 + -- does not apply when fancy tab bar is in use
216 + background = '#c7c7c7',
218 + -- The active tab is the one that has focus in the window
219 + active_tab = {
220 + -- The color of the background area for the tab
221 + bg_color = '#c7c7c7',
222 + -- The color of the text for the tab
223 + fg_color = '#9170b5',
225 + -- Specify whether you want 'Half', 'Normal' or 'Bold' intensity for the
226 + -- label shown for this tab.
227 + -- The default is 'Normal'
228 + intensity = 'Bold',
230 + -- Specify whether you want 'None', 'Single' or 'Double' underline for
231 + -- label shown for this tab.
232 + -- The default is 'None'
233 + underline = 'Double',
235 + -- Specify whether you want the text to be italic or not
236 + -- for this tab. The default is false.
237 + italic = false,
239 + -- Specify whether you want the text to be rendered with strikethrough
240 + -- or not for this tab. The default is false.
241 + strikethrough = false,
242 + },
244 + -- Inactive tabs are the tabs that do not have focus
245 + inactive_tab = {
246 + bg_color = '#c7c7c7',
247 + fg_color = '#929292',
248 + intensity = 'Normal',
250 + -- The same options that were listed under the `active_tab` section above
251 + -- can also be used for `inactive_tab`.
252 + },
254 + -- You can configure some alternate styling when the mouse pointer
255 + -- moves over inactive tabs
256 + inactive_tab_hover = {
257 + bg_color = '#646464',
258 + fg_color = '#929292',
259 + italic = true,
261 + -- The same options that were listed under the `active_tab` section above
262 + -- can also be used for `inactive_tab_hover`.
263 + },
265 + -- The new tab button that let you create new tabs
266 + new_tab = {
267 + bg_color = '#c7c7c7',
268 + fg_color = '#c9c9c9',
270 + -- The same options that were listed under the `active_tab` section above
271 + -- can also be used for `new_tab`.
272 + },
274 + -- You can configure some alternate styling when the mouse pointer
275 + -- moves over the new tab button
276 + new_tab_hover = {
277 + bg_color = '#646464',
278 + fg_color = '#929292',
279 + italic = true,
281 + -- The same options that were listed under the `active_tab` section above
282 + -- can also be used for `new_tab_hover`.
283 + },
284 + },

wezterm/bugabinga/status.lua

Added
new file mode 100644
1 +local wez = require 'wezterm'
3 +local DELIMITER = ' · '
5 +local zoomed = function(pane)
6 + local tab = pane:tab()
7 + local any_is_zoomed = false
8 + if tab then
9 + for _, info in ipairs(tab:panes_with_info()) do
10 + if info.is_zoomed then
11 + any_is_zoomed = true
12 + end
13 + end
14 + end
15 + return any_is_zoomed and '🔎 Zoomed Pane' .. DELIMITER or ''
16 +end
18 +-- Show which key table is active in the status area
19 +wez.on('update-right-status', function(window, pane)
20 + local name = window:active_key_table()
21 + local current_workspace = ' ' .. window:active_workspace() .. DELIMITER
22 + local zoomed_state = zoomed(pane)
24 + local status = name or current_workspace
25 + window:set_right_status(zoomed_state .. status)
26 +end)

wezterm/bugabinga/workspaces.lua

Added
new file mode 100644
1 +local wez = require 'wezterm'
2 +local mux = wez.mux
5 +local get_my_code_workspace = function()
6 + if wez.target_triple:find('windows') then
7 + return 'W:'
8 + else
9 + return os.getenv 'HOME' .. '/Workspace'
10 + end
11 +end
13 +local WORKSPACE = get_my_code_workspace()
15 +wez.on('gui-attached', function()
16 + -- maximize all displayed windows on startup
17 + local workspace = mux.get_active_workspace()
18 + for _, window in ipairs(mux.all_windows()) do
19 + if window:get_workspace() == workspace then
20 + window:gui_window():maximize()
21 + end
22 + end
23 +end)
25 +-- NOTE(oli): errors in here do not show up as configuration errors
26 +-- check the log file in the wezterm mux server runtime directory
27 +-- e.g. /run/user/1000/wezterm/log
28 +wez.on('mux-startup', function()
29 + local nugu_ws = 'nugu development'
30 + local nugu_cwd = WORKSPACE .. '/nugu'
31 + local nugu_tab, nugu_pane, nugu_window = mux.spawn_window { cwd = nugu_cwd, workspace = nugu_ws }
32 + local nugu_top_pane = nugu_pane:split { cwd = nugu_cwd, args = { 'hx', '.' }, direction = 'Top', size = 0.82 }
33 + nugu_top_pane:split { cwd = nugu_cwd, direction = 'Left', size = 0.66 }
34 + nugu_tab:set_title 'Nugu Development'
37 + local tini_lang_ws = 'tini_lang development'
38 + local tini_lang_cwd = WORKSPACE .. '/tini_lang'
39 + local tini_lang_tab, tini_lang_pane, tini_lang_window = mux.spawn_window { cwd = tini_lang_cwd, workspace =
40 + tini_lang_ws }
41 + local tini_lang_top_pane = tini_lang_pane:split { cwd = tini_lang_cwd, args = { 'hx', '.' }, direction = 'Top', size = 0.82 }
42 + tini_lang_top_pane:split { cwd = tini_lang_cwd, direction = 'Left', size = 0.66 }
43 + tini_lang_tab:set_title 'tini_lang Development'
46 + local reign_ws = 'reign development'
47 + local reign_cwd = WORKSPACE .. '/reign'
48 + local reign_tab, reign_pane, reign_window = mux.spawn_window { cwd = reign_cwd, args = { 'hx', '.' }, workspace =
49 + reign_ws }
50 + local reign_right_pane = reign_pane:split { cwd = reign_cwd, direction = 'Right', size = 0.36 }
51 + reign_right_pane:split { cwd = reign_cwd, direction = 'Bottom', size = 0.33 }
52 + reign_tab:set_title 'Reign Development'
53 + reign_pane:activate()
54 + -- FIXME(oli): the text gets send, but seemingly before nushell is ready to receive input
55 + reign_right_pane:send_text 'watch src {clear; just build}'
58 + local dork_ws = 'dorkfiles editing'
59 + local dork_cwd = WORKSPACE .. '/dotfiles'
60 + local dork_tab, dork_pane, dork_window = mux.spawn_window { cwd = dork_cwd, workspace = dork_ws }
61 + local dork_top_pane = dork_pane:split { direction = 'Top', size = 0.55 }
62 + dork_top_pane:split { cwd = dork_cwd, args = { 'hx', '.' }, direction = 'Left', size = 0.7 }
63 + dork_tab:set_title 'Dorkfiles Editing'
64 + --TODO(oli): create tabs for configs in dorkfiles that i edit often (wezterm, helix, bootstripper,...)
65 + local wezterm_config_tab = dork_window:spawn_tab { cwd = dork_cwd .. '/wezterm' }
66 + wezterm_config_tab:set_title 'Wezterm'
67 + wezterm_config_tab:active_pane():split { args = { 'hx', '.' }, direction = 'Left', size = 0.7 }
68 + local helix_config_tab = dork_window:spawn_tab { cwd = dork_cwd .. '/helix' }
69 + helix_config_tab:set_title 'Helix'
70 + helix_config_tab:active_pane():split { args = { 'hx', '.' }, direction = 'Left', size = 0.7 }
73 + local default_ws = 'default'
74 + local default_tab, default_pane, default_window = mux.spawn_window { workspace = default_ws }
75 + local default_top_pane = default_pane:split { direction = 'Top', size = 0.5 }
76 + default_pane:split { direction = 'Right', size = 0.5 }
77 + default_top_pane:split { direction = 'Right', size = 0.5 }
78 + default_window:spawn_tab { args = { 'btm' } }
79 + default_tab:set_title 'Default'
80 + default_top_pane:activate()
82 + mux.set_active_workspace(default_ws)
83 +end)

wezterm/wezterm.lua

Modified
1 1 local wez = require 'wezterm'
2 2 local nugu = require 'bugabinga.nugu'
4 -local color_scheme = 'nugu-dark' -- not there yet ;)
5 -local color_schemes = nugu
4 +local key_binds = require 'bugabinga.key_binds'
5 +local dark_mode = require 'bugabinga.dark_mode'
6 +local workspaces = require 'bugabinga.workspaces'
7 +local status = require 'bugabinga.status'
7 9 local hostname = wez.hostname()
8 10 local enable_wayland = false
13 15 if hostname == 'x230' then
14 16 enable_wayland = true
15 - window_decorations = 'NONE'
17 + window_decorations = 'RESIZE'
16 18 elseif hostname == 'pop-os' then
17 19 font_size = 12
18 20 elseif hostname == 'PC-00625' then
19 21 font_size = 14
20 - font = wez.font 'Cascadia Mono'
22 + font = wez.font 'Cascadia Code'
21 23 window_decorations = 'TITLE|RESIZE'
24 --- Show which key table is active in the status area
25 -wez.on('update-right-status', function(window, pane)
26 - local name = window:active_key_table()
27 - if name then
28 - name = 'TABLE: ' .. name
29 - end
30 - window:set_right_status(name or '')
31 -end)
33 -local leader = { key = 'Space', mods = 'CTRL|SHIFT', timeout_milliseconds = 1000 }
34 -local keys = {
35 - -- CTRL+SHIFT+Space, followed by 'r' will put us in resize-pane
36 - -- mode until we cancel that mode.
37 - {
38 - key = 'r',
39 - mods = 'LEADER',
40 - action = wez.action.ActivateKeyTable {
41 - name = 'resize_pane',
42 - one_shot = false,
43 - },
44 - },
46 - -- CTRL+SHIFT+Space, followed by 'a' will put us in activate-pane
47 - -- mode until we press some other key or until 1 second (1000ms)
48 - -- of time elapses
49 - {
50 - key = 'a',
51 - mods = 'LEADER',
52 - action = wez.action.ActivateKeyTable {
53 - name = 'activate_pane',
54 - timeout_milliseconds = 1000,
55 - },
56 - },
58 - -- Copy
59 - {
60 - key = 'c',
61 - mods = 'CTRL|SHIFT',
62 - action = wez.action.CopyTo 'Clipboard',
63 - },
64 - -- Paste
65 - {
66 - key = 'v',
67 - mods = 'CTRL|SHIFT',
68 - action = wez.action.PasteFrom 'Clipboard',
69 - },
70 - -- Split left-right
71 - {
72 - key = 'v',
73 - mods = 'LEADER',
74 - action = wez.action.SplitHorizontal { domain = 'CurrentPaneDomain' },
75 - },
76 - -- Split top-bottom
77 - {
78 - key = 'h',
79 - mods = 'LEADER',
80 - action = wez.action.SplitVertical { domain = 'CurrentPaneDomain' },
81 - },
82 - {
83 - key = 't',
84 - mods = 'LEADER',
85 - action = wez.action.SpawnTab 'CurrentPaneDomain',
86 - },
87 - {
88 - key = 'w',
89 - mods = 'LEADER',
90 - action = wez.action.CloseCurrentTab { confirm = true },
91 - },
92 - {
93 - key = 'q',
94 - mods = 'LEADER',
95 - action = wez.action.QuitApplication,
96 - },
99 -local key_tables = {
100 - -- Defines the keys that are active in our resize-pane mode.
101 - -- Since we're likely to want to make multiple adjustments,
102 - -- we made the activation one_shot=false. We therefore need
103 - -- to define a key assignment for getting out of this mode.
104 - -- 'resize_pane' here corresponds to the name="resize_pane" in
105 - -- the key assignments above.
106 - resize_pane = {
107 - { key = 'LeftArrow', action = wez.action.AdjustPaneSize { 'Left', 1 } },
108 - { key = 'h', action = wez.action.AdjustPaneSize { 'Left', 1 } },
110 - { key = 'RightArrow', action = wez.action.AdjustPaneSize { 'Right', 1 } },
111 - { key = 'l', action = wez.action.AdjustPaneSize { 'Right', 1 } },
113 - { key = 'UpArrow', action = wez.action.AdjustPaneSize { 'Up', 1 } },
114 - { key = 'k', action = wez.action.AdjustPaneSize { 'Up', 1 } },
116 - { key = 'DownArrow', action = wez.action.AdjustPaneSize { 'Down', 1 } },
117 - { key = 'j', action = wez.action.AdjustPaneSize { 'Down', 1 } },
119 - -- Cancel the mode by pressing escape
120 - { key = 'Escape', action = 'PopKeyTable' },
121 - },
123 - -- Defines the keys that are active in our activate-pane mode.
124 - -- 'activate_pane' here corresponds to the name="activate_pane" in
125 - -- the key assignments above.
126 - activate_pane = {
127 - { key = 'LeftArrow', action = wez.action.ActivatePaneDirection 'Left' },
128 - { key = 'h', action = wez.action.ActivatePaneDirection 'Left' },
130 - { key = 'RightArrow', action = wez.action.ActivatePaneDirection 'Right' },
131 - { key = 'l', action = wez.action.ActivatePaneDirection 'Right' },
133 - { key = 'UpArrow', action = wez.action.ActivatePaneDirection 'Up' },
134 - { key = 'k', action = wez.action.ActivatePaneDirection 'Up' },
136 - { key = 'DownArrow', action = wez.action.ActivatePaneDirection 'Down' },
137 - { key = 'j', action = wez.action.ActivatePaneDirection 'Down' },
138 - },
141 27 return {
28 + -- logs key presses
29 + debug_key_events = true,
142 31 font = font,
143 32 font_size = font_size,
144 - color_scheme = color_scheme,
145 - color_schemes = color_schemes,
146 - default_prog = { 'nu' },
33 + warn_about_missing_glyphs = false,
34 + color_scheme = dark_mode,
35 + color_schemes = nugu,
36 + window_background_opacity = 1.0,
37 + -- nightly
38 + -- win32_system_backdrop = 'Acrylic',
39 + default_cwd = wez.home_dir,
40 + default_prog = { 'nu', '--login', '--interactive' },
41 + default_cursor_style = 'SteadyBlock',
42 + cursor_blink_rate = 0,
43 + cursor_thickness = '0.6cell',
147 44 window_decorations = window_decorations,
148 45 enable_tab_bar = true,
149 46 -- if this is hidden, we cannot see the right status area
150 47 hide_tab_bar_if_only_one_tab = false,
48 + use_fancy_tab_bar = false;
151 49 check_for_updates = false,
152 50 show_update_window = false,
153 51 audible_bell = 'Disabled',
156 54 fade_out_duration_ms = 75,
157 55 target = 'CursorColor',
57 + inactive_pane_hsb = {
58 + saturation = 0.33,
59 + brightness = 0.66,
60 + },
159 61 tab_max_width = 24,
160 62 enable_wayland = enable_wayland,
161 63 window_padding = {
165 67 bottom = 8,
167 69 disable_default_key_bindings = true,
168 - leader = leader,
169 - keys = keys,
170 - key_tables = key_tables,
70 + leader = key_binds.leader,
71 + keys = key_binds.keys,
72 + key_tables = key_binds.key_tables,
73 + unix_domains = {
74 + {
75 + name = 'unix',
76 + } },
77 + default_domain = 'unix',
78 + default_gui_startup_args = { 'connect', 'unix' },
79 + -- TODO(oli): create different launchers per OS
80 + launch_menu = {
81 + {
82 + label = 'Bash',
83 + args = {'bash', '-l'},
84 + }
85 + }

wezterm/wezterm.service

Added
new file mode 100644
1 +[Unit]
2 +Description=Wezterm Multiplexing Server
4 +[Service]
5 +# start with system shell as parent in order to inherit environment variables
6 +ExecStart=/bin/bash -c /usr/bin/wezterm-mux-server
7 +Restart=on-failure
9 +[Install]
10 +WantedBy=default.target

x230.symlinks

Modified
7 7 cargo/config.toml
8 8 ~/.cargo/config.toml
10 -nushell
11 -~/.config/nushell
10 +nushell/completions
11 +~/.config/nushell/completions
13 +nushell/config.nu
14 +~/.config/nushell/config.nu
16 +nushell/env.nu
17 +~/.config/nushell/env.nu
19 +nushell/modules
20 +~/.config/nushell/modules
22 +nushell/plugin.nu
23 +~/.config/nushell/plugin.nu
13 25 icc/thinkpad_x230.icc
14 26 ~/.config/icc/thinkpad_x230.icc
25 37 wezterm
26 38 ~/.config/wezterm
40 +wezterm/wezterm.service
41 +~/.config/systemd/user/wezterm.service
28 43 helix/config.toml
29 44 ~/.config/helix/config.toml
46 +helix/languages.toml
47 +~/.config/helix/languages.toml
31 49 helix/themes
32 50 ~/.config/helix/themes
52 +helix/systemd/helix-dark-mode.service
53 +~/.config/systemd/user/helix-dark-mode.service
55 +xplr
56 +~/.config/xplr
34 58 river
35 59 ~/.config/river

xplr/init.lua

Added
new file mode 100644
1 +---@diagnostic disable
3 +-- See https://xplr.dev/en/upgrade-guide
4 +version = "0.21.1"
6 +local xplr = xplr
8 +-- @diagnostics enable
11 +-- Set it to `true` if you want to enable mouse scrolling.
12 +--
13 +-- Type: boolean
14 +xplr.config.general.enable_mouse = false