nixos/hosts/nixos/home/starship.nix
2026-01-21 23:58:24 +01:00

206 lines
4.9 KiB
Nix
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{
config,
pkgs,
lib,
...
}:
{
programs.starship = {
enable = true;
enableFishIntegration = true;
settings = {
add_newline = false;
format = lib.concatStrings [
"[](red)"
"$os"
"$username"
"[](bg:peach fg:red)"
"$directory"
"[](bg:yellow fg:peach)"
"$git_branch"
"$git_status"
"[](fg:yellow bg:green)"
"$c"
"$rust"
"$golang"
"$nodejs"
"$php"
"$java"
"$kotlin"
"$haskell"
"$python"
"[](fg:green bg:sapphire)"
"$conda"
"[](fg:sapphire bg:lavender)"
"$time"
"[ ](fg:lavender)"
"$cmd_duration"
"$line_break"
"$character"
];
palette = "catppuccin_mocha";
os = {
disabled = false;
style = "bg:red fg:crust";
symbols = {
Windows = "";
Ubuntu = "󰕈";
SUSE = "";
Raspbian = "󰐿";
Mint = "󰣭";
Macos = "󰀵";
Manjaro = "";
Linux = "󰌽";
Gentoo = "󰣨";
Fedora = "󰣛";
Alpine = "";
Amazon = "";
Android = "";
AOSC = "";
Arch = "󰣇";
Artix = "󰣇";
CentOS = "";
Debian = "󰣚";
Redhat = "󱄛";
RedHatEnterprise = "󱄛";
};
};
username = {
show_always = true;
style_user = "bg:red fg:crust";
style_root = "bg:red fg:crust";
format = "[ $user]($style)";
};
directory = {
style = "bg:peach fg:crust";
format = "[ $path ]($style)";
truncation_length = 3;
truncation_symbol = "/";
substitutions = {
"Documents" = "󰈙 ";
"Downloads" = " ";
"Music" = "󰝚 ";
"Pictures" = " ";
"Developer" = "󰲋 ";
};
};
git_branch = {
symbol = "";
style = "bg:yellow";
format = "[[ $symbol $branch ](fg:crust bg:yellow)]($style)";
};
git_status = {
style = "bg:yellow";
format = "[[($all_status$ahead_behind )](fg:crust bg:yellow)]($style)";
};
nodejs = {
symbol = "";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
c = {
symbol = " ";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
rust = {
symbol = "";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
golang = {
symbol = "";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
php = {
symbol = "";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
java = {
symbol = " ";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
kotlin = {
symbol = "";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
haskell = {
symbol = "";
style = "bg:green";
format = "[[ $symbol( $version) ](fg:crust bg:green)]($style)";
};
python = {
symbol = "";
style = "bg:green";
format = "[[ $symbol( $version)(\\(#$virtualenv\\)) ](fg:crust bg:green)]($style)";
};
docker_context = {
symbol = "";
style = "bg:sapphire";
format = "[[ $symbol( $context) ](fg:crust bg:sapphire)]($style)";
};
conda = {
symbol = " ";
style = "fg:crust bg:sapphire";
format = "[$symbol$environment ]($style)";
ignore_base = false;
};
time = {
disabled = false;
time_format = "%R";
style = "bg:lavender";
format = "[[ $time ](fg:crust bg:lavender)]($style)";
};
line_break = {
disabled = true;
};
character = {
disabled = false;
success_symbol = "[](bold fg:green)";
error_symbol = "[](bold fg:red)";
vimcmd_symbol = "[](bold fg:green)";
vimcmd_replace_one_symbol = "[](bold fg:lavender)";
vimcmd_replace_symbol = "[](bold fg:lavender)";
vimcmd_visual_symbol = "[](bold fg:yellow)";
};
cmd_duration = {
show_milliseconds = true;
format = " in $duration ";
style = "bg:lavender";
disabled = false;
show_notifications = true;
min_time_to_notify = 45000;
};
};
};
# Enable the Catppuccin starship module to provide the palette
catppuccin.starship.enable = true;
catppuccin.flavor = "mocha";
}