Fixed system for nushell

This commit is contained in:
2024-11-05 17:36:01 -04:00
parent aa897b10af
commit b333a4f693
8 changed files with 176 additions and 61 deletions

View File

@@ -1,5 +0,0 @@
{
programs.autojump = {
enable = true;
};
}

View File

@@ -2,6 +2,9 @@
home.shellAliases = { home.shellAliases = {
sudo = "sudo --preserve-env=PATH"; sudo = "sudo --preserve-env=PATH";
}; };
programs.nushell.shellAliases = {
sudo = "sudo --preserve-env=PATH";
};
home.packages = with pkgs; [ home.packages = with pkgs; [
# AI Tools # AI Tools

View File

@@ -2,7 +2,6 @@
imports = [ imports = [
./aria2.nix ./aria2.nix
./atuin.nix ./atuin.nix
./autojump.nix
./bat.nix ./bat.nix
./bottom.nix ./bottom.nix
./btop.nix ./btop.nix

View File

@@ -23,4 +23,7 @@
home.shellAliases = { home.shellAliases = {
lgit = "lazygit"; lgit = "lazygit";
}; };
programs.nushell.shellAliases = {
lgit = "lazygit";
};
} }

View File

@@ -1,5 +1,12 @@
{ {pkgs, ...}: {
programs.nushell = { programs.nushell = {
enable = true; enable = true;
}; };
home.packages = with pkgs; [
nushellPlugins.query
nushellPlugins.formats
nushellPlugins.gstat
nushellPlugins.net
];
} }

View File

@@ -1,62 +1,168 @@
add_newline = false "$schema" = 'https://starship.rs/config-schema.json'
# A minimal left prompt
format = """$directory$character""" format = """
palette = "catppuccin_mocha" [](color_orange)\
# move the rest of the prompt to the right $username\
right_format = """$all""" [](bg:color_yellow fg:color_orange)\
command_timeout = 1000 $directory\
[](fg:color_yellow bg:color_aqua)\
$git_branch\
$git_status\
[](fg:color_aqua bg:color_blue)\
$c\
$rust\
$golang\
$nodejs\
$php\
$java\
$kotlin\
$haskell\
$python\
[](fg:color_blue bg:color_bg3)\
$docker_context\
$conda\
[](fg:color_bg3 bg:color_bg1)\
$time\
[ ](fg:color_bg1)\
$line_break$character"""
palette = 'gruvbox_dark'
[palettes.gruvbox_dark]
color_fg0 = '#fbf1c7'
color_bg1 = '#3c3836'
color_bg3 = '#665c54'
color_blue = '#458588'
color_aqua = '#689d6a'
color_green = '#98971a'
color_orange = '#d65d0e'
color_purple = '#b16286'
color_red = '#cc241d'
color_yellow = '#d79921'
[os]
disabled = false
style = "bg:color_orange fg:color_fg0"
[os.symbols]
Windows = "󰍲"
Ubuntu = "󰕈"
SUSE = ""
Raspbian = "󰐿"
Mint = "󰣭"
Macos = "󰀵"
Manjaro = ""
Linux = "󰌽"
Gentoo = "󰣨"
Fedora = "󰣛"
Alpine = ""
Amazon = ""
Android = ""
Arch = "󰣇"
Artix = "󰣇"
EndeavourOS = ""
CentOS = ""
Debian = "󰣚"
Redhat = "󱄛"
RedHatEnterprise = "󱄛"
Pop = ""
[username]
show_always = true
style_user = "bg:color_orange fg:color_fg0"
style_root = "bg:color_orange fg:color_fg0"
format = '[ $user ]($style)'
[directory]
style = "fg:color_fg0 bg:color_yellow"
format = "[ $path ]($style)"
truncation_length = 3
truncation_symbol = "…/"
[directory.substitutions] [directory.substitutions]
'~/tests/starship-custom' = 'work-project' "Documents" = "󰈙 "
"Downloads" = " "
"Music" = "󰝚 "
"Pictures" = " "
"Developer" = "󰲋 "
[git_branch] [git_branch]
format = '[$symbol$branch(:$remote_branch)]($style)' symbol = ""
style = "bg:color_aqua"
format = '[[ $symbol $branch ](fg:color_fg0 bg:color_aqua)]($style)'
[aws] [git_status]
format = '[$symbol(profile: "$profile" )(\(region: $region\) )]($style)' style = "bg:color_aqua"
disabled = false format = '[[($all_status$ahead_behind )](fg:color_fg0 bg:color_aqua)]($style)'
style = 'bold blue'
symbol = " " [nodejs]
symbol = ""
style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[c]
symbol = " "
style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[rust]
symbol = ""
style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[golang] [golang]
format = '[ ](bold cyan)' symbol = ""
style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[kubernetes] [php]
symbol = '☸ ' symbol = ""
disabled = true style = "bg:color_blue"
detect_files = ['Dockerfile'] format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
format = '[$symbol$context( \($namespace\))]($style) '
contexts = [ [java]
{ context_pattern = "arn:aws:eks:us-west-2:577926974532:cluster/zd-pvc-omer", style = "green", context_alias = "omerxx", symbol = " " }, symbol = ""
] style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[kotlin]
symbol = ""
style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[haskell]
symbol = ""
style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[python]
symbol = ""
style = "bg:color_blue"
format = '[[ $symbol( $version) ](fg:color_fg0 bg:color_blue)]($style)'
[docker_context] [docker_context]
disabled = true symbol = ""
style = "bg:color_bg3"
format = '[[ $symbol( $context) ](fg:#83a598 bg:color_bg3)]($style)'
[palettes.catppuccin_mocha] [conda]
rosewater = "#f5e0dc" style = "bg:color_bg3"
flamingo = "#f2cdcd" format = '[[ $symbol( $environment) ](fg:#83a598 bg:color_bg3)]($style)'
pink = "#f5c2e7"
mauve = "#cba6f7" [time]
red = "#f38ba8" disabled = false
maroon = "#eba0ac" time_format = "%R"
peach = "#fab387" style = "bg:color_bg1"
yellow = "#f9e2af" format = '[[  $time ](fg:color_fg0 bg:color_bg1)]($style)'
green = "#a6e3a1"
teal = "#94e2d5" [line_break]
sky = "#89dceb" disabled = false
sapphire = "#74c7ec"
blue = "#89b4fa" [character]
lavender = "#b4befe" disabled = false
text = "#cdd6f4" success_symbol = '[](bold fg:color_green)'
subtext1 = "#bac2de" error_symbol = '[](bold fg:color_red)'
subtext0 = "#a6adc8" vimcmd_symbol = '[](bold fg:color_green)'
overlay2 = "#9399b2" vimcmd_replace_one_symbol = '[](bold fg:color_purple)'
overlay1 = "#7f849c" vimcmd_replace_symbol = '[](bold fg:color_purple)'
overlay0 = "#6c7086" vimcmd_visual_symbol = '[](bold fg:color_yellow)'
surface2 = "#585b70"
surface1 = "#45475a"
surface0 = "#313244"
base = "#1e1e2e"
mantle = "#181825"
crust = "#11111b"

View File

@@ -4,7 +4,9 @@
}; };
home.shellAliases = { home.shellAliases = {
zd = "z"; j = "z";
zdi = "zi"; };
programs.nushell.shellAliases = {
j = "z";
}; };
} }

View File

@@ -69,7 +69,7 @@
description = "panotaka"; description = "panotaka";
extraGroups = ["networkmanager" "wheel" "libvirtd"]; extraGroups = ["networkmanager" "wheel" "libvirtd"];
initialPassword = "panotaka"; initialPassword = "panotaka";
shell = pkgs.nu; shell = pkgs.nushell;
openssh.authorizedKeys.keys = [ openssh.authorizedKeys.keys = [
]; ];
}; };