mirror of
https://github.com/ivuorinen/dotfiles.git
synced 2026-03-10 07:02:50 +00:00
feat(shell): switch to starship because it's fast
This commit is contained in:
@@ -68,8 +68,6 @@ have antigen && {
|
|||||||
[ -f "${DOTFILES}/config/fzf/fzf.zsh" ] \
|
[ -f "${DOTFILES}/config/fzf/fzf.zsh" ] \
|
||||||
&& source "${DOTFILES}/config/fzf/fzf.zsh"
|
&& source "${DOTFILES}/config/fzf/fzf.zsh"
|
||||||
|
|
||||||
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
|
# Start starship
|
||||||
# shellcheck source=config/zsh/p10k.zsh
|
eval "$(starship init zsh)"
|
||||||
export P10K_LOCATION="$XDG_CONFIG_HOME/zsh/p10k.zsh"
|
|
||||||
[[ ! -f $P10K_LOCATION ]] || source "$P10K_LOCATION"
|
|
||||||
|
|
||||||
|
|||||||
@@ -83,12 +83,9 @@ x-default-antigen-bundles()
|
|||||||
|
|
||||||
# these should be available if there's need
|
# these should be available if there's need
|
||||||
have brew && antigen bundle brew
|
have brew && antigen bundle brew
|
||||||
have nvm && antigen bundle nvm
|
# have nvm && antigen bundle nvm
|
||||||
have nvm && antigen bundle "$DOTFILES/config/zsh/plugins/nvm-auto-use"
|
have nvm && antigen bundle "$DOTFILES/config/zsh/plugins/nvm-auto-use"
|
||||||
have php && antigen bundle php
|
have php && antigen bundle php
|
||||||
have python && antigen bundle MichaelAquilina/zsh-autoswitch-virtualenv
|
have python && antigen bundle MichaelAquilina/zsh-autoswitch-virtualenv
|
||||||
have rvm && antigen bundle unixorn/rvm-plugin
|
have rvm && antigen bundle unixorn/rvm-plugin
|
||||||
|
|
||||||
# the theme to use
|
|
||||||
antigen theme romkatv/powerlevel10k
|
|
||||||
}
|
}
|
||||||
|
|||||||
143
config/starship.toml
Normal file
143
config/starship.toml
Normal file
@@ -0,0 +1,143 @@
|
|||||||
|
# Get editor completions based on the config schema
|
||||||
|
"$schema" = 'https://starship.rs/config-schema.json'
|
||||||
|
|
||||||
|
format = """
|
||||||
|
$os\
|
||||||
|
$directory\
|
||||||
|
$git_branch\
|
||||||
|
$git_state\
|
||||||
|
$git_status\
|
||||||
|
$fill\
|
||||||
|
$battery\
|
||||||
|
$username\
|
||||||
|
$hostname\
|
||||||
|
$aws\
|
||||||
|
$gcloud\
|
||||||
|
$conda\
|
||||||
|
$golang\
|
||||||
|
$nodejs\
|
||||||
|
$php\
|
||||||
|
$python\
|
||||||
|
$package\
|
||||||
|
$line_break\
|
||||||
|
$character"""
|
||||||
|
|
||||||
|
# Timeout for commands executed by starship (in milliseconds).
|
||||||
|
# command_timeout = 1000
|
||||||
|
|
||||||
|
[character]
|
||||||
|
success_symbol = "[→](bold green)"
|
||||||
|
error_symbol = "[→](red)"
|
||||||
|
vimcmd_symbol = "[←](green)"
|
||||||
|
|
||||||
|
[aws]
|
||||||
|
symbol = " "
|
||||||
|
format = '[$symbol($profile )(\($region\) )(\[$duration\] )]($style)'
|
||||||
|
|
||||||
|
[cmd_duration]
|
||||||
|
disabled = true
|
||||||
|
|
||||||
|
[directory]
|
||||||
|
read_only = " "
|
||||||
|
style = "blue"
|
||||||
|
|
||||||
|
[docker_context]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[fill]
|
||||||
|
symbol = '·'
|
||||||
|
style = 'bold black'
|
||||||
|
|
||||||
|
[gcloud]
|
||||||
|
format = ' [($symbol)$account(@$domain)(\($region\))]($style) '
|
||||||
|
|
||||||
|
[git_branch]
|
||||||
|
symbol = " "
|
||||||
|
truncation_length = 20
|
||||||
|
truncation_symbol = '…'
|
||||||
|
ignore_branches = ['master', 'main']
|
||||||
|
|
||||||
|
[git_status]
|
||||||
|
up_to_date = '✓'
|
||||||
|
staged = '[++\($count\)](green)'
|
||||||
|
|
||||||
|
[git_state]
|
||||||
|
format = '\([$state( $progress_current/$progress_total)]($style)\) '
|
||||||
|
style = "bright-black"
|
||||||
|
|
||||||
|
[git_metrics]
|
||||||
|
added_style = 'bold blue'
|
||||||
|
format = '[+$added]($added_style)/[-$deleted]($deleted_style) '
|
||||||
|
disabled = false
|
||||||
|
|
||||||
|
[golang]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[hostname]
|
||||||
|
ssh_symbol = " "
|
||||||
|
|
||||||
|
[nodejs]
|
||||||
|
symbol = " "
|
||||||
|
format = '[$symbol($version )]($style)'
|
||||||
|
version_format = '${major}.${minor}'
|
||||||
|
|
||||||
|
[os]
|
||||||
|
format = "[$symbol]($style) "
|
||||||
|
style = "bold blue"
|
||||||
|
disabled = false
|
||||||
|
|
||||||
|
[os.symbols]
|
||||||
|
Alpaquita = " "
|
||||||
|
Alpine = " "
|
||||||
|
Amazon = " "
|
||||||
|
Android = " "
|
||||||
|
Arch = " "
|
||||||
|
Artix = " "
|
||||||
|
CentOS = " "
|
||||||
|
Debian = " "
|
||||||
|
DragonFly = " "
|
||||||
|
Emscripten = " "
|
||||||
|
EndeavourOS = " "
|
||||||
|
Fedora = " "
|
||||||
|
FreeBSD = " "
|
||||||
|
Garuda = " "
|
||||||
|
Gentoo = " "
|
||||||
|
HardenedBSD = " "
|
||||||
|
Illumos = " "
|
||||||
|
Linux = " "
|
||||||
|
Mabox = " "
|
||||||
|
Macos = " "
|
||||||
|
Manjaro = " "
|
||||||
|
Mariner = " "
|
||||||
|
MidnightBSD = " "
|
||||||
|
Mint = " "
|
||||||
|
NetBSD = " "
|
||||||
|
NixOS = " "
|
||||||
|
OpenBSD = " "
|
||||||
|
openSUSE = " "
|
||||||
|
OracleLinux = " "
|
||||||
|
Pop = " "
|
||||||
|
Raspbian = " "
|
||||||
|
Redhat = " "
|
||||||
|
RedHatEnterprise = " "
|
||||||
|
Redox = " "
|
||||||
|
Solus = " "
|
||||||
|
SUSE = " "
|
||||||
|
Ubuntu = " "
|
||||||
|
Unknown = " "
|
||||||
|
Windows = " "
|
||||||
|
|
||||||
|
[package]
|
||||||
|
symbol = " "
|
||||||
|
format = '[$symbol($version )]($style)'
|
||||||
|
version_format = '${major}.${minor}'
|
||||||
|
|
||||||
|
[php]
|
||||||
|
format = '[$symbol($version )]($style)'
|
||||||
|
version_format = '${major}.${minor}'
|
||||||
|
|
||||||
|
[python]
|
||||||
|
symbol = " "
|
||||||
|
format = "[$virtualenv]($style) "
|
||||||
|
style = "bright-black"
|
||||||
|
|
||||||
1713
config/zsh/p10k.zsh
1713
config/zsh/p10k.zsh
File diff suppressed because it is too large
Load Diff
@@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
SCRIPT=$(basename "$0")
|
SCRIPT=$(basename "$0")
|
||||||
|
|
||||||
VERSION_NVM="v0.39.3"
|
VERSION_NVM="v0.39.5"
|
||||||
|
|
||||||
# shellcheck source=./../../scripts/shared.sh
|
# shellcheck source=./../../scripts/shared.sh
|
||||||
source "$SHARED_SCRIPT"
|
source "$SHARED_SCRIPT"
|
||||||
|
|||||||
Reference in New Issue
Block a user