_inputs: { lib, pkgs, ... }: { users.extraUsers.minijackson.packages = [ pkgs.sd ]; home-manager.sharedModules = [ { programs.starship = { enable = true; enableZshIntegration = true; settings = lib.mkMerge [ { directory = { fish_style_pwd_dir_length = 2; repo_root_style = "bold cyan"; style = "bold white"; truncate_to_repo = false; }; hostname = { ssh_symbol = "ssh "; style = "bold blue"; }; jobs.symbol = "+ "; nix_shell.style = "bold blue"; package.style = "bold green"; rust.style = "bold dimmed yellow"; custom = { jj = { command = '' jj log -r@ -l1 --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"), ) ' ''; detect_folders = [ ".jj" ]; symbol = "jj "; }; jjstate = { 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." "" ''; detect_folders = [ ".jj" ]; }; }; } (lib.importTOML ./starship-plain-text-symbols.toml) ]; }; } ]; }