merge
This commit is contained in:
@@ -214,6 +214,10 @@ require('lspconfig')['tsserver'].setup{
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
}
|
||||
require('lspconfig')['clangd'].setup{
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
}
|
||||
EOF
|
||||
|
||||
lua <<EOF
|
||||
|
||||
10
zsh/.zshrc
10
zsh/.zshrc
@@ -3,6 +3,7 @@ export EDITOR=nvim
|
||||
export PATH=$HOME/bin:$HOME/.local/bin:/usr/local/bin:/opt/local/bin:$PATH
|
||||
|
||||
ulimit -n 65536 200000
|
||||
ulimit -f unlimited
|
||||
|
||||
# eksctl
|
||||
fpath=($fpath ~/.zsh/completion)
|
||||
@@ -35,8 +36,15 @@ alias nvdf='nvim $HOME/.dotfiles/README.md'
|
||||
alias cls='clear'
|
||||
export PATH="/opt/homebrew/opt/protobuf@3.6/bin:$PATH"
|
||||
|
||||
export NVM_DIR="$HOME/.nvm"
|
||||
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
||||
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||
|
||||
for conf in "$HOME/.config/zsh/config.d/"*.zsh; do
|
||||
source "${conf}"
|
||||
done
|
||||
unset conf
|
||||
export PATH="${KREW_ROOT:-$HOME/.krew}/bin:$PATH"
|
||||
|
||||
export STARSHIP_CONFIG=~/.config/zsh/starship.toml
|
||||
|
||||
eval "$(starship init zsh)"
|
||||
|
||||
@@ -78,5 +78,4 @@ export SSH_KEY_PATH="~/.ssh/rsa_id"
|
||||
# users are encouraged to define aliases within the ZSH_CUSTOM folder.
|
||||
# For a full list of active aliases, run `alias`.
|
||||
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
|
||||
eval "$(starship init zsh)"
|
||||
|
||||
|
||||
38
zsh/config.d/starship.zsh
Normal file
38
zsh/config.d/starship.zsh
Normal file
@@ -0,0 +1,38 @@
|
||||
# find out which distribution we are running on
|
||||
LFILE="/etc/*-release"
|
||||
MFILE="/System/Library/CoreServices/SystemVersion.plist"
|
||||
if [[ -f $LFILE ]]; then
|
||||
_distro=$(awk '/^ID=/' /etc/*-release | awk -F'=' '{ print tolower($2) }')
|
||||
elif [[ -f $MFILE ]]; then
|
||||
_distro="macos"
|
||||
fi
|
||||
|
||||
# set an icon based on the distro
|
||||
# make sure your font is compatible with https://github.com/lukas-w/font-logos
|
||||
case $_distro in
|
||||
*kali*) ICON="ﴣ";;
|
||||
*arch*) ICON="";;
|
||||
*debian*) ICON="";;
|
||||
*raspbian*) ICON="";;
|
||||
*ubuntu*) ICON="";;
|
||||
*elementary*) ICON="";;
|
||||
*fedora*) ICON="";;
|
||||
*coreos*) ICON="";;
|
||||
*gentoo*) ICON="";;
|
||||
*mageia*) ICON="";;
|
||||
*centos*) ICON="";;
|
||||
*opensuse*|*tumbleweed*) ICON="";;
|
||||
*sabayon*) ICON="";;
|
||||
*slackware*) ICON="";;
|
||||
*linuxmint*) ICON="";;
|
||||
*alpine*) ICON="";;
|
||||
*aosc*) ICON="";;
|
||||
*nixos*) ICON="";;
|
||||
*devuan*) ICON="";;
|
||||
*manjaro*) ICON="";;
|
||||
*rhel*) ICON="";;
|
||||
*macos*) ICON="";;
|
||||
*) ICON="";;
|
||||
esac
|
||||
|
||||
export STARSHIP_DISTRO="$ICON"
|
||||
164
zsh/starship.toml
Normal file
164
zsh/starship.toml
Normal file
@@ -0,0 +1,164 @@
|
||||
# ~/.config/starship.toml
|
||||
|
||||
# Inserts a blank line between shell prompts
|
||||
add_newline = true
|
||||
|
||||
# Change command timeout from 500 to 1000 ms
|
||||
command_timeout = 1000
|
||||
|
||||
# Change the default prompt format
|
||||
format = """
|
||||
[╭╴](238)$env_var \
|
||||
$username\
|
||||
$hostname\
|
||||
$localip\
|
||||
$directory\
|
||||
$time\
|
||||
$line_break\
|
||||
[|](238)$shlvl\
|
||||
$singularity\
|
||||
$vcsh\
|
||||
$git_branch\
|
||||
$git_commit\
|
||||
$git_state\
|
||||
$git_metrics\
|
||||
$git_status\
|
||||
$kubernetes\
|
||||
$hg_branch\
|
||||
$docker_context\
|
||||
$package\
|
||||
$c\
|
||||
$cmake\
|
||||
$cobol\
|
||||
$daml\
|
||||
$dart\
|
||||
$deno\
|
||||
$dotnet\
|
||||
$elixir\
|
||||
$elm\
|
||||
$erlang\
|
||||
$golang\
|
||||
$haskell\
|
||||
$helm\
|
||||
$java\
|
||||
$julia\
|
||||
$kotlin\
|
||||
$lua\
|
||||
$nim\
|
||||
$nodejs\
|
||||
$ocaml\
|
||||
$perl\
|
||||
$php\
|
||||
$pulumi\
|
||||
$purescript\
|
||||
$python\
|
||||
$raku\
|
||||
$rlang\
|
||||
$red\
|
||||
$ruby\
|
||||
$rust\
|
||||
$scala\
|
||||
$swift\
|
||||
$terraform\
|
||||
$vlang\
|
||||
$vagrant\
|
||||
$zig\
|
||||
$buf\
|
||||
$nix_shell\
|
||||
$conda\
|
||||
$meson\
|
||||
$spack\
|
||||
$memory_usage\
|
||||
$aws\
|
||||
$gcloud\
|
||||
$openstack\
|
||||
$azure\
|
||||
$crystal\
|
||||
$custom\
|
||||
$sudo\
|
||||
$cmd_duration\
|
||||
$jobs\
|
||||
$battery\
|
||||
$status\
|
||||
$container\
|
||||
$shell\
|
||||
$line_break\
|
||||
[╰─](238)$character"""
|
||||
|
||||
# Change the default prompt characters
|
||||
[character]
|
||||
error_symbol = "[✘](bold red)"
|
||||
success_symbol = ""
|
||||
|
||||
[time]
|
||||
disabled = false
|
||||
|
||||
# Shows an icon that should be included by zshrc script based on the distribution or os
|
||||
[env_var.STARSHIP_DISTRO]
|
||||
format = '[$env_value](white)'
|
||||
variable = "STARSHIP_DISTRO"
|
||||
disabled = false
|
||||
|
||||
# Shows the username
|
||||
[username]
|
||||
style_user = "white"
|
||||
style_root = "white"
|
||||
format = "[$user]($style) "
|
||||
disabled = false
|
||||
show_always = true
|
||||
|
||||
[hostname]
|
||||
ssh_only = true
|
||||
format = "on [$hostname](bold yellow) "
|
||||
disabled = false
|
||||
|
||||
[directory]
|
||||
truncate_to_repo = true
|
||||
home_symbol = " ~"
|
||||
read_only_style = "197"
|
||||
read_only = " "
|
||||
format = "at [$path]($style)[$read_only]($read_only_style) "
|
||||
|
||||
[git_branch]
|
||||
symbol = " "
|
||||
format = "[$symbol$branch]($style) "
|
||||
style = "bold green"
|
||||
|
||||
[git_status]
|
||||
format = '[\(( $all_status)($ahead_behind)\)]($style) '
|
||||
style = "bold green"
|
||||
conflicted = "🏳"
|
||||
up_to_date = " "
|
||||
untracked = " "
|
||||
ahead = "⇡${count}"
|
||||
diverged = "⇕⇡${ahead_count}⇣${behind_count}"
|
||||
behind = "⇣${count}"
|
||||
stashed = " "
|
||||
modified = " "
|
||||
staged = '[++$count ](green)'
|
||||
renamed = "襁 "
|
||||
deleted = " "
|
||||
|
||||
[kubernetes]
|
||||
format = '[///](238) [ﴱ $context](bold purple) '
|
||||
disabled = false
|
||||
|
||||
[python]
|
||||
format = '[///](238) [${symbol}${pyenv_prefix}(${version} )(\($virtualenv\) )]($style)'
|
||||
symbol = " "
|
||||
python_binary = "python3"
|
||||
disabled = false
|
||||
|
||||
[nodejs]
|
||||
format = "[///](238) [ $version](bold green) "
|
||||
disabled = false
|
||||
|
||||
[golang]
|
||||
format = "[///](238) [$symbol($version )]($style)"
|
||||
symbol = "ﳑ "
|
||||
|
||||
[package]
|
||||
disabled = true
|
||||
|
||||
[gcloud]
|
||||
format = '[///](238) [$symbol$account(@$domain)(\($region\))]($style) '
|
||||
Reference in New Issue
Block a user