my NixOS and nix-darwin config
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

a bunch of edits

+62 -62
+17 -5
modules/home/prompts/oh-my-posh/default.nix
··· 1 - { config, lib, pkgs, ... }: 1 + { 2 + config, 3 + lib, 4 + pkgs, 5 + ... 6 + }: 2 7 with lib; 3 - let cfg = config.nyx.oh-my-posh; 4 - in { 8 + let 9 + cfg = config.nyx.oh-my-posh; 10 + in 11 + { 5 12 6 - options.nyx.oh-my-posh = { enable = mkEnableOption "Oh-My-Posh"; }; 13 + options.nyx.oh-my-posh = { 14 + enable = mkEnableOption "Oh-My-Posh"; 15 + }; 7 16 8 17 config = mkIf (cfg.enable) { 9 18 home.packages = [ pkgs.oh-my-posh ]; 10 19 11 - home.file.".config/oh-my-posh/theme.toml".source = ./mypure.omp.toml; 20 + home.file.".config/oh-my-posh/theme.toml".source = 21 + config.lib.file.mkOutOfStoreSymlink 22 + 23 + "${config.home.homeDirectory}/Nyx/modules/home/prompts/oh-my-posh/mypure.omp.toml"; 12 24 }; 13 25 14 26 }
+13 -40
modules/home/prompts/oh-my-posh/mypure.omp.toml
··· 1 - console_title_template = '{{if .Root}}(Admin){{end}} {{.PWD}}' 1 + console_title_template = '{{if .Root}}(Admin){{end}} {{.PWD}}' 2 2 version = 3 3 3 4 4 [transient_prompt] 5 5 template = '❯ ' 6 - foreground = '#B48EAD' 7 - foreground_templates = ['{{ if gt .Code 0 }}#BF616A{{ end }}'] 6 + foreground = '#9ECE6A' 7 + foreground_templates = ['{{ if gt .Code 0 }}#F7768E{{ end }}'] 8 8 9 9 [upgrade] 10 10 source = 'cdn' ··· 16 16 type = 'prompt' 17 17 alignment = 'left' 18 18 19 + # Segment 1: User (Green) @ Hostname (True Gray) 19 20 [[blocks.segments]] 20 - template = '{{ .UserName }} ' 21 - foreground = '#FD971E' 21 + # We set the base foreground to Green for the user 22 + # We use <#858585> to force the @ and Hostname to be Gray 23 + template = '{{ .UserName }}<#858585>@{{ .HostName }}</> ' 24 + foreground = '#9ECE6A' 22 25 type = 'session' 23 26 style = 'plain' 24 27 28 + # Segment 2: Path (Orange) 25 29 [[blocks.segments]] 26 30 template = '{{ .Path }} ' 27 - foreground = '#98E025' 31 + foreground = '#FF9E64' 28 32 type = 'path' 29 33 style = 'plain' 30 34 ··· 34 38 [[blocks]] 35 39 type = 'prompt' 36 40 alignment = 'left' 37 - 38 - [[blocks.segments]] 39 - template = '{{ .UpstreamIcon }}{{ .HEAD }}{{if .BranchStatus }} {{ .BranchStatus }}{{ end }}{{ if .Working.Changed }}<#FFAFD7>*</>{{ .Working.String }}{{ end }}{{ if and (.Working.Changed) (.Staging.Changed) }} |{{ end }}{{ if .Staging.Changed }}  {{ .Staging.String }}{{ end }}{{ if gt .StashCount 0 }}  {{ .StashCount }}{{ end }} ' 40 - foreground = '#6C6C6C' 41 - type = 'git' 42 - style = 'plain' 43 - 44 - [blocks.segments.properties] 45 - branch_ahead_icon = '<#88C0D0>⇡ </>' 46 - branch_behind_icon = '<#88C0D0>⇣ </>' 47 - branch_icon = '' 48 - fetch_stash_count = true 49 - fetch_status = true 50 - fetch_upstream_icon = true 51 - github_icon = '' 52 - 53 - [[blocks]] 54 - type = 'prompt' 55 - alignment = 'left' 56 - 57 - [[blocks.segments]] 58 - template = ' {{ .FormattedMs }} ' 59 - foreground = '#A3BE8C' 60 - type = 'executiontime' 61 - style = 'plain' 62 - 63 - [blocks.segments.properties] 64 - style = 'austin' 65 - 66 - [[blocks]] 67 - type = 'prompt' 68 - alignment = 'left' 69 41 newline = true 70 42 43 + # Segment 3: Prompt symbol (Green -> Red on error) 71 44 [[blocks.segments]] 72 45 template = '❯ ' 73 - foreground = '#B48EAD' 46 + foreground = '#9ECE6A' 74 47 type = 'status' 75 48 style = 'plain' 76 - foreground_templates = ['{{ if gt .Code 0 }}#BF616A{{ end }}'] 49 + foreground_templates = ['{{ if gt .Code 0 }}#F7768E{{ end }}'] 77 50 78 51 [blocks.segments.properties] 79 52 always_enabled = true
+27 -16
modules/home/shells/zsh/default.nix
··· 1 - { lib, pkgs, config, ... }: 1 + { 2 + lib, 3 + pkgs, 4 + config, 5 + ... 6 + }: 2 7 with lib; 3 8 let 4 9 cfg = config.nyx.zsh; ··· 9 14 rm ~/.zsh_history_bad 10 15 11 16 ''; 12 - in { 17 + in 18 + { 13 19 14 - options.nyx.zsh = { enable = mkEnableOption "Zsh"; }; 20 + options.nyx.zsh = { 21 + enable = mkEnableOption "Zsh"; 22 + }; 15 23 16 24 config = mkIf (cfg.enable) { 17 25 programs.zoxide.enable = true; 18 - home.packages = with pkgs; [ fd eza zsh_history_fix ]; 26 + home.packages = with pkgs; [ 27 + fd 28 + eza 29 + zsh_history_fix 30 + ]; 19 31 programs.zsh = { 20 32 enable = true; 21 33 autocd = true; ··· 26 38 # TODO: these need to be fixed lmao 27 39 shellAliases = { 28 40 darl = "sudo darwin-rebuild switch --flake /Users/suri/dev/dots"; 29 - darling = '' 30 - cd /Users/suri/dev/dots && git add -A && git commit -m "." && sudo darwin-rebuild switch --flake /Users/suri/dev/dots && git push''; 41 + darling = ''cd /Users/suri/dev/dots && git add -A && git commit -m "." && sudo darwin-rebuild switch --flake /Users/suri/dev/dots && git push''; 31 42 32 43 dots = "z ~/dev/dots"; 33 - fcd = '' 34 - cd "$(find ~/coding/ ~/storage/ -type d -not \( -path "*/.git/*" -o -path "*/target/*" -o -path "*/.venv/*" -o -path "*/node_modules/*" -o -path "*/venv/*" -o -path "*/build/*" -o -path "*/.*/*" \) -print 2>/dev/null | fzf)" ''; 44 + fcd = ''cd "$(find ~/coding/ ~/storage/ -type d -not \( -path "*/.git/*" -o -path "*/target/*" -o -path "*/.venv/*" -o -path "*/node_modules/*" -o -path "*/venv/*" -o -path "*/build/*" -o -path "*/.*/*" \) -print 2>/dev/null | fzf)" ''; 35 45 36 46 l = "exa"; 37 47 ls = "exa"; ··· 42 52 43 53 zt = "zathura"; 44 54 45 - tars = 46 - "cd /Users/suri/dev/personal/tars/tars-tui && cargo run --release"; 55 + tars = "cd /Users/suri/dev/personal/tars/tars-tui && cargo run --release"; 47 56 48 - ezk = 49 - " /Users/suri/dev/personal/Emergence/target/release/emergence_cli"; 57 + ezk = " /Users/suri/dev/personal/Emergence/target/release/emergence_cli"; 50 58 }; 51 59 52 60 initContent = '' ··· 55 63 56 64 eval "$(zoxide init zsh)" 57 65 # eval "$(starship init zsh)" 58 - # 59 - eval "$(/opt/homebrew/bin/brew shellenv)" 66 + ${lib.optionalString pkgs.stdenv.isDarwin '' 67 + if [ -f /opt/homebrew/bin/brew ]; then 68 + eval "$(/opt/homebrew/bin/brew shellenv)" 69 + export PATH="/opt/homebrew/opt/libiconv/bin:$PATH" 70 + fi 71 + ''} 60 72 61 73 function y() { 62 74 local tmp="$(mktemp -t "yazi-cwd.XXXXXX")" ··· 81 93 open "$output_file" # Open the generated PDF 82 94 } 83 95 84 - export PATH="/opt/homebrew/opt/libiconv/bin:$PATH" 85 - export PATH="/Users/suri/.cargo/bin:$PATH" 96 + export PATH="/Users/suri/.cargo/bin:$PATH" &> /dev/null 86 97 87 98 eval "$(${pkgs.oh-my-posh}/bin/oh-my-posh init zsh --config ${config.home.homeDirectory}/.config/oh-my-posh/theme.toml)" 88 99
-1
users/suri/Daedalus.nix
··· 4 4 5 5 nyx.aerospace.enable = true; 6 6 nyx.ghostty.enable = true; 7 - nyx.helix.enable = true; 8 7 nyx.orbstack.enable = true; 9 8 10 9
+4
users/suri/Khaos.nix
··· 6 6 nyx.zsh.enable = true; 7 7 nyx.zellij.enable = true; 8 8 9 + home.sessionVariables = { 10 + COLORTERM = "truecolor"; 11 + }; 12 + 9 13 }
+1
users/suri/common.nix
··· 6 6 nyx.oh-my-posh.enable = true; 7 7 nyx.zsh.enable = true; 8 8 nyx.zellij.enable = true; 9 + nyx.helix.enable = true; 9 10 10 11 programs.direnv = { 11 12 enable = true;