2023-04-07 11:19:58 +02:00
|
|
|
|
{ config, lib, ... }:
|
|
|
|
|
with lib;
|
|
|
|
|
let
|
|
|
|
|
cfg = config.eboskma.programs.starship;
|
|
|
|
|
in
|
|
|
|
|
{
|
2024-02-05 11:46:52 +01:00
|
|
|
|
options.eboskma.programs.starship = {
|
|
|
|
|
enable = mkEnableOption "starship";
|
|
|
|
|
};
|
2023-04-07 11:19:58 +02:00
|
|
|
|
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
|
programs.starship = {
|
|
|
|
|
enable = true;
|
|
|
|
|
settings = {
|
2024-03-27 11:33:17 +01:00
|
|
|
|
# Sets user-defined palette
|
|
|
|
|
palette = "catppuccin_macchiato";
|
|
|
|
|
|
2023-04-07 11:19:58 +02:00
|
|
|
|
character = {
|
2024-03-27 11:33:17 +01:00
|
|
|
|
# Note the use of Catppuccin color 'maroon'
|
|
|
|
|
success_symbol = "[[♥](green) ❯](maroon)";
|
|
|
|
|
error_symbol = "[❯](red)";
|
|
|
|
|
vimcmd_symbol = "[❮](green)";
|
|
|
|
|
};
|
|
|
|
|
directory = {
|
|
|
|
|
truncation_length = 4;
|
|
|
|
|
read_only = " "; # Icon: lock
|
|
|
|
|
# Catppuccin 'lavender'
|
|
|
|
|
style = "bold lavender";
|
|
|
|
|
};
|
|
|
|
|
username = {
|
|
|
|
|
format = "[$user]($style) on ";
|
|
|
|
|
style_user = "bold #bd93f9";
|
2023-04-07 11:19:58 +02:00
|
|
|
|
};
|
2024-03-27 11:33:17 +01:00
|
|
|
|
status = {
|
|
|
|
|
disabled = false;
|
|
|
|
|
format = "[$symbol $status]($style) ";
|
|
|
|
|
};
|
|
|
|
|
|
2023-04-07 11:19:58 +02:00
|
|
|
|
cmd_duration.style = "bold #f1fa8c";
|
2024-03-27 11:33:17 +01:00
|
|
|
|
|
|
|
|
|
aws.disabled = true;
|
|
|
|
|
buf.symbol = " ";
|
|
|
|
|
c.symbol = " ";
|
|
|
|
|
conda.symbol = " ";
|
|
|
|
|
crystal.symbol = " ";
|
|
|
|
|
dart.symbol = " ";
|
2023-04-07 11:19:58 +02:00
|
|
|
|
docker_context.symbol = " ";
|
|
|
|
|
elixir.symbol = " ";
|
2024-03-27 11:33:17 +01:00
|
|
|
|
elm.symbol = " ";
|
|
|
|
|
fennel.symbol = " ";
|
|
|
|
|
fossil_branch.symbol = " ";
|
|
|
|
|
git_branch = {
|
|
|
|
|
symbol = " ";
|
|
|
|
|
style = "bold #ff79c6";
|
|
|
|
|
};
|
|
|
|
|
git_status = {
|
|
|
|
|
style = "bold #ff5555";
|
|
|
|
|
};
|
|
|
|
|
golang.symbol = " ";
|
|
|
|
|
guix_shell.symbol = " ";
|
|
|
|
|
haskell.symbol = " ";
|
|
|
|
|
haxe.symbol = " ";
|
|
|
|
|
hg_branch.symbol = " ";
|
|
|
|
|
hostname = {
|
|
|
|
|
ssh_symbol = " ";
|
|
|
|
|
style = "bold #ff5555";
|
|
|
|
|
};
|
|
|
|
|
java.symbol = " ";
|
|
|
|
|
julia.symbol = " ";
|
|
|
|
|
kotlin.symbol = " ";
|
|
|
|
|
lua.symbol = " ";
|
2023-05-15 14:28:41 +02:00
|
|
|
|
memory_usage = {
|
|
|
|
|
symbol = " "; # Icon: memory
|
|
|
|
|
disabled = false;
|
|
|
|
|
};
|
2024-03-27 11:33:17 +01:00
|
|
|
|
meson.symbol = " ";
|
|
|
|
|
nim.symbol = " ";
|
|
|
|
|
nix_shell.symbol = " ";
|
|
|
|
|
nodejs.symbol = " ";
|
|
|
|
|
ocaml.symbol = " ";
|
|
|
|
|
os.symbols = {
|
|
|
|
|
Alpaquita = " ";
|
|
|
|
|
Alpine = " ";
|
|
|
|
|
AlmaLinux = " ";
|
|
|
|
|
Amazon = " ";
|
|
|
|
|
Android = " ";
|
|
|
|
|
Arch = " ";
|
|
|
|
|
Artix = " ";
|
|
|
|
|
CentOS = " ";
|
|
|
|
|
Debian = " ";
|
|
|
|
|
DragonFly = " ";
|
|
|
|
|
Emscripten = " ";
|
|
|
|
|
EndeavourOS = " ";
|
|
|
|
|
Fedora = " ";
|
|
|
|
|
FreeBSD = " ";
|
|
|
|
|
Garuda = " ";
|
|
|
|
|
Gentoo = " ";
|
|
|
|
|
HardenedBSD = " ";
|
|
|
|
|
Illumos = " ";
|
|
|
|
|
Kali = " ";
|
|
|
|
|
Linux = " ";
|
|
|
|
|
Mabox = " ";
|
|
|
|
|
Macos = " ";
|
|
|
|
|
Manjaro = " ";
|
|
|
|
|
Mariner = " ";
|
|
|
|
|
MidnightBSD = " ";
|
|
|
|
|
Mint = " ";
|
|
|
|
|
NetBSD = " ";
|
|
|
|
|
NixOS = " ";
|
|
|
|
|
OpenBSD = " ";
|
|
|
|
|
openSUSE = " ";
|
|
|
|
|
OracleLinux = " ";
|
|
|
|
|
Pop = " ";
|
|
|
|
|
Raspbian = " ";
|
|
|
|
|
Redhat = " ";
|
|
|
|
|
RedHatEnterprise = " ";
|
|
|
|
|
RockyLinux = " ";
|
|
|
|
|
Redox = " ";
|
|
|
|
|
Solus = " ";
|
|
|
|
|
SUSE = " ";
|
|
|
|
|
Ubuntu = " ";
|
|
|
|
|
Unknown = " ";
|
|
|
|
|
Void = " ";
|
|
|
|
|
Windows = " ";
|
|
|
|
|
};
|
2023-05-15 14:28:41 +02:00
|
|
|
|
package.symbol = " "; # Icon: package_variant_closed
|
2024-03-27 11:33:17 +01:00
|
|
|
|
perl.symbol = " ";
|
|
|
|
|
php.symbol = " ";
|
|
|
|
|
pijul_channel.symbol = " ";
|
2023-04-07 11:19:58 +02:00
|
|
|
|
python.symbol = " ";
|
2024-03-27 11:33:17 +01:00
|
|
|
|
rlang.symbol = " ";
|
|
|
|
|
ruby.symbol = " ";
|
2023-04-07 11:19:58 +02:00
|
|
|
|
rust.symbol = " ";
|
2024-03-27 11:33:17 +01:00
|
|
|
|
scala.symbol = " ";
|
|
|
|
|
swift.symbol = " ";
|
2023-04-07 11:19:58 +02:00
|
|
|
|
time.disabled = false;
|
2024-03-27 11:33:17 +01:00
|
|
|
|
zig.symbol = " ";
|
|
|
|
|
|
2024-12-13 09:33:30 +01:00
|
|
|
|
custom = {
|
|
|
|
|
jj = {
|
|
|
|
|
command = ''
|
|
|
|
|
jj log -r@ -n1 --ignore-working-copy --no-graph --color always -T '
|
|
|
|
|
separate(" ",
|
|
|
|
|
bookmarks.map(|x| if(
|
|
|
|
|
x.name().substr(0, 10).starts_with(x.name()),
|
|
|
|
|
x.name().substr(0, 10),
|
|
|
|
|
x.name().substr(0, 9) ++ "…")
|
|
|
|
|
).join(" "),
|
|
|
|
|
tags.map(|x| if(
|
|
|
|
|
x.name().substr(0, 10).starts_with(x.name()),
|
|
|
|
|
x.name().substr(0, 10),
|
|
|
|
|
x.name().substr(0, 9) ++ "…")
|
|
|
|
|
).join(" "),
|
|
|
|
|
surround("\"","\"",
|
|
|
|
|
if(
|
|
|
|
|
description.first_line().substr(0, 24).starts_with(description.first_line()),
|
|
|
|
|
description.first_line().substr(0, 24),
|
|
|
|
|
description.first_line().substr(0, 23) ++ "…"
|
|
|
|
|
)
|
|
|
|
|
),
|
|
|
|
|
if(conflict, "conflict"),
|
|
|
|
|
if(divergent, "divergent"),
|
|
|
|
|
if(hidden, "hidden"),
|
|
|
|
|
)
|
|
|
|
|
'
|
|
|
|
|
'';
|
|
|
|
|
when = "jj root";
|
|
|
|
|
symbol = "jj";
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
jjstate = {
|
|
|
|
|
when = "jj root";
|
|
|
|
|
command = ''
|
|
|
|
|
jj log -r@ -n1 --no-graph -T "" --stat | tail -n1 | sd "(\d+) files? changed, (\d+) insertions?\(\+\), (\d+) deletions?\(-\)" ' ''${1}m ''${2}+ ''${3}-' | sd " 0." ""
|
|
|
|
|
'';
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
2024-03-27 11:33:17 +01:00
|
|
|
|
palettes = {
|
|
|
|
|
catppuccin_macchiato = {
|
|
|
|
|
rosewater = "#f5e0dc";
|
|
|
|
|
flamingo = "#f2cdcd";
|
|
|
|
|
pink = "#f5c2e7";
|
|
|
|
|
mauve = "#cba6f7";
|
|
|
|
|
red = "#f38ba8";
|
|
|
|
|
maroon = "#eba0ac";
|
|
|
|
|
peach = "#fab387";
|
|
|
|
|
yellow = "#f9e2af";
|
|
|
|
|
green = "#a6e3a1";
|
|
|
|
|
teal = "#94e2d5";
|
|
|
|
|
sky = "#89dceb";
|
|
|
|
|
sapphire = "#74c7ec";
|
|
|
|
|
blue = "#89b4fa";
|
|
|
|
|
lavender = "#b4befe";
|
|
|
|
|
text = "#cdd6f4";
|
|
|
|
|
subtext1 = "#bac2de";
|
|
|
|
|
subtext0 = "#a6adc8";
|
|
|
|
|
overlay2 = "#9399b2";
|
|
|
|
|
overlay1 = "#7f849c";
|
|
|
|
|
overlay0 = "#6c7086";
|
|
|
|
|
surface2 = "#585b70";
|
|
|
|
|
surface1 = "#45475a";
|
|
|
|
|
surface0 = "#313244";
|
|
|
|
|
base = "#1e1e2e";
|
|
|
|
|
mantle = "#181825";
|
|
|
|
|
crust = "#11111b";
|
|
|
|
|
};
|
2023-04-07 11:19:58 +02:00
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
}
|