From 9a044139bf6eae1c768db4358c98e2be1d2c5c85 Mon Sep 17 00:00:00 2001 From: Eric Renfro Date: Sun, 24 Dec 2023 12:21:30 -0500 Subject: [PATCH] Add starship and more adjustments --- dot_config/private_fish/config.fish.tmpl | 11 +++++ dot_config/starship.toml.tmpl | 54 ++++++++++++++++++++++++ 2 files changed, 65 insertions(+) create mode 100644 dot_config/starship.toml.tmpl diff --git a/dot_config/private_fish/config.fish.tmpl b/dot_config/private_fish/config.fish.tmpl index df79df2..1739929 100644 --- a/dot_config/private_fish/config.fish.tmpl +++ b/dot_config/private_fish/config.fish.tmpl @@ -1,8 +1,11 @@ set -gx KUBE_EDITOR micro set -gx VISUAL micro set -gx EDITOR micro +set -gx GOPATH {{ .chezmoi.homeDir }}/.go set -gx ANSIBLE_FORCE_COLOR true set -gx ANSIBLE_HOST_KEY_CHECKING False +set -gx PY_COLORS true +set -gx GPG_TTY (tty) fish_add_path "{{ .chezmoi.homeDir }}/bin" fish_add_path "{{ .chezmoi.homeDir }}/.local/bin" @@ -22,10 +25,18 @@ if type -q atuin atuin init fish | source end +if type -q thefuck + thefuck --alias | source +end + if type -q starship starship init fish | source end +if type -q zoxide + zoxide init fish | source +end + if status is-interactive # Commands to run in interactive sessions can go here set -g fish_escape_delay_ms 100 diff --git a/dot_config/starship.toml.tmpl b/dot_config/starship.toml.tmpl new file mode 100644 index 0000000..46703f4 --- /dev/null +++ b/dot_config/starship.toml.tmpl @@ -0,0 +1,54 @@ +"$schema" = 'https://starship.rs/config-schema.json' + +add_newline = true + +format = """\ + $username\ + $directory\ + $kubernetes\ + $git_branch\ + $git_commit\ + $git_state\ + $git_status\ + $character\ + """ + +[character] +success_symbol = "\n[❯](bold green)" +error_symbol = "\n[✖](bold red)" + +[cmd_duration] +min_time = 500 + +[username] +disabled = false +show_always = false + +[directory] +disabled = false +truncation_length = 8 +truncate_to_repo = true +read_only = " " +home_symbol = " " + +[kubernetes] +disabled = false +symbol = "󱃾 " +format = "[\\[$symbol$context \\($namespace\\)\\]]($style) " +style = "bold bright-green" + +[python] +disabled = false +format = '\[[${symbol}${pyenv_prefix}(${version})(\($virtualenv\))]($style)\]' +symbol = " " + +[git_branch] +disabled = false +symbol = " " + +[git_commit] +disabled = false +commit_hash_length = 8 +only_detached = false +style = "grey" +tag_symbol = " "