Compare commits
No commits in common. "d4d3c1af559166bd08df1bf5c910a19010ef31df" and "7ae0b331cff7e27a431b59481f2d6def0eb6f78d" have entirely different histories.
d4d3c1af55
...
7ae0b331cf
10
.bashrc
10
.bashrc
@ -2,12 +2,18 @@
|
||||
|
||||
set -o vi
|
||||
|
||||
shopt -s autocd progcomp_alias
|
||||
|
||||
FZF_ALT_C_OPTS=--walker=dir,follow
|
||||
. /usr/share/fzf/key-bindings.bash
|
||||
|
||||
shopt -s autocd progcomp_alias
|
||||
|
||||
for f in "$HOME/.config/bash/"*.bash; do
|
||||
# shellcheck disable=SC1090
|
||||
. "$f"
|
||||
done
|
||||
|
||||
complete -r -D
|
||||
for f in kill kubectl git; do
|
||||
# shellcheck disable=SC1090
|
||||
. "/usr/share/bash-completion/completions/$f"
|
||||
done
|
||||
|
2
.config/Trolltech.conf
Normal file
2
.config/Trolltech.conf
Normal file
@ -0,0 +1,2 @@
|
||||
[Qt]
|
||||
style=Materia-dark
|
@ -1,8 +1,8 @@
|
||||
[yw5n]
|
||||
source = imaps://ange@yw5n.com@ssl0.ovh.net
|
||||
source-cred-cmd = pass show yw5ncom/ange@yw5n.com | head -n1
|
||||
source-cred-cmd = pass show email/ange@yw5n.com | head -n1
|
||||
outgoing = smtps://ange@yw5n.com@ssl0.ovh.net
|
||||
outgoing-cred-cmd = pass show yw5ncom/ange@yw5n.com | head -n1
|
||||
outgoing-cred-cmd = pass show email/ange@yw5n.com | head -n1
|
||||
default = INBOX
|
||||
from = "Ange DUHAYON" <ange@yw5n.com>
|
||||
cache-headers = true
|
||||
@ -13,9 +13,9 @@ pgp-opportunistic-encrypt = true
|
||||
|
||||
[duhayon]
|
||||
source = imaps://ange@duhayon.com@ssl0.ovh.net
|
||||
source-cred-cmd = pass show duhayoncom/ange@duhayon.com | head -n1
|
||||
source-cred-cmd = pass show email/ange@duhayon.com | head -n1
|
||||
outgoing = smtps://ange@duhayon.com@ssl0.ovh.net
|
||||
outgoing-cred-cmd = pass show duhayoncom/ange@duhayon.com | head -n1
|
||||
outgoing-cred-cmd = pass show email/ange@duhayon.com | head -n1
|
||||
default = INBOX
|
||||
from = "Ange DUHAYON" <ange@duhayon.com>
|
||||
cache-headers = true
|
||||
|
@ -4,6 +4,13 @@ function gi() {
|
||||
curl -fL "https://www.toptal.com/developers/gitignore/api/$*"
|
||||
}
|
||||
|
||||
function _gi() {
|
||||
mapfile -t COMPREPLY < <(compgen -W \
|
||||
"$(curl -sfL https://www.toptal.com/developers/gitignore/api/list | tr ',' '\n')" \
|
||||
-- "${COMP_WORDS[1]}")
|
||||
}
|
||||
complete -F _gi gi
|
||||
|
||||
alias g='git' \
|
||||
ga='git add' \
|
||||
gaa='git add --all' \
|
||||
@ -22,7 +29,6 @@ alias g='git' \
|
||||
gl='git pull' \
|
||||
glo='git log --oneline --decorate' \
|
||||
gmr='git merge' \
|
||||
gp='git push' \
|
||||
gr='git remote' \
|
||||
grb='git rebase' \
|
||||
grev='git revert' \
|
||||
|
@ -18,6 +18,13 @@ function kns() {
|
||||
tee "$cache" <<< "$1"
|
||||
}
|
||||
|
||||
function _kns() {
|
||||
mapfile -t COMPREPLY < <(compgen -W \
|
||||
"$(kubectl get namespace -o jsonpath='{..metadata.name}')" \
|
||||
-- "${COMP_WORDS[1]}")
|
||||
}
|
||||
complete -F _kns kns
|
||||
|
||||
function kctx() {
|
||||
local cache="$HOME/.local/state/${FUNCNAME[0]}"
|
||||
|
||||
@ -34,6 +41,14 @@ function kctx() {
|
||||
tee "$cache" <<< "$1"
|
||||
}
|
||||
|
||||
function _kctx() {
|
||||
mapfile -t COMPREPLY < <(compgen -W \
|
||||
"$(kubectl config get-contexts -o name)" \
|
||||
-- "${COMP_WORDS[1]}")
|
||||
}
|
||||
complete -F _kctx kctx
|
||||
|
||||
|
||||
alias kga='kubectl get "$(kubectl api-resources --verbs=list --namespaced -oname | grep -v event | paste -sd,)"'
|
||||
|
||||
alias k=kubectl \
|
||||
|
@ -1,14 +1,11 @@
|
||||
function man() {
|
||||
env GROFF_NO_SGR=1 \
|
||||
LESS_TERMCAP_mb=$'\e[01;31m' \
|
||||
LESS_TERMCAP_md=$'\e[01;31m' \
|
||||
LESS_TERMCAP_me=$'\e[00m' \
|
||||
LESS_TERMCAP_so=$'\e[01;33m\e[44m' \
|
||||
LESS_TERMCAP_se=$'\e[00m' \
|
||||
LESS_TERMCAP_us=$'\e[01;32m' \
|
||||
LESS_TERMCAP_ue=$'\e[00m' \
|
||||
man "$@"
|
||||
}
|
||||
export GROFF_NO_SGR=1 \
|
||||
LESS_TERMCAP_mb=$'\e[01;31m' \
|
||||
LESS_TERMCAP_md=$'\e[01;31m' \
|
||||
LESS_TERMCAP_me=$'\e[00m' \
|
||||
LESS_TERMCAP_so=$'\e[01;33m\e[44m' \
|
||||
LESS_TERMCAP_se=$'\e[00m' \
|
||||
LESS_TERMCAP_us=$'\e[01;32m' \
|
||||
LESS_TERMCAP_ue=$'\e[00m'
|
||||
|
||||
. /usr/share/git/git-prompt.sh
|
||||
GIT_PS1_SHOWDIRTYSTATE=1
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit 61a4a615366c470a4e9ca8f8b45718b6b92af73f
|
||||
Subproject commit f2bfde705ac752c52544d5cfa8b0aee0a766c1ed
|
@ -1 +1 @@
|
||||
Subproject commit 53b32a6aa3e1de224e82f88cbdc08584c753adb7
|
||||
Subproject commit 122b4d3db1616c1f1305b847c5ed2217c4c329f1
|
20
.config/zsh/.zprofile
Normal file
20
.config/zsh/.zprofile
Normal file
@ -0,0 +1,20 @@
|
||||
export SSH_AUTH_SOCK; SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
||||
|
||||
[ -z "$DISPLAY" ] && [ "$XDG_VTNR" = 1 ] && {
|
||||
GUILOG="$HOME/.local/state/gui.log"
|
||||
|
||||
mv -f "$GUILOG" "$GUILOG.old" || true
|
||||
|
||||
export XDG_CURRENT_DESKTOP=Unity
|
||||
exec startx &> "$GUILOG"
|
||||
}
|
||||
|
||||
[ -z "$DISPLAY" ] && [ "$XDG_VTNR" = 1 ] && {
|
||||
GUILOG="$HOME/.local/state/gui.log"
|
||||
|
||||
mv -f "$GUILOG" "$GUILOG.old" || true
|
||||
|
||||
#export WLR_DRM_NO_MODIFIERS=1
|
||||
export XDG_CURRENT_DESKTOP=Unity
|
||||
exec river &> "$GUILOG"
|
||||
}
|
35
.config/zsh/.zshrc
Normal file
35
.config/zsh/.zshrc
Normal file
@ -0,0 +1,35 @@
|
||||
autoload -Uz bashcompinit compinit
|
||||
zmodload zsh/complist
|
||||
|
||||
fpath=("$ZDOTDIR/completions" $fpath)
|
||||
compinit -d "$XDG_CACHE_HOME/.zcompdump-$ZSH_VERSION"
|
||||
bashcompinit
|
||||
|
||||
. "$ZDOTDIR/theme.zsh"
|
||||
. "$ZDOTDIR/input.zsh"
|
||||
. /usr/share/fzf/key-bindings.zsh
|
||||
|
||||
for f in "$ZDOTDIR"/aliases/*; do
|
||||
. "$f"
|
||||
done
|
||||
|
||||
setopt INTERACTIVE_COMMENTS
|
||||
setopt LONG_LIST_JOBS
|
||||
|
||||
setopt AUTO_MENU
|
||||
setopt COMPLETE_IN_WORD
|
||||
unsetopt FLOW_CONTROL
|
||||
|
||||
setopt AUTO_CD
|
||||
setopt RM_STAR_SILENT
|
||||
|
||||
setopt HIST_IGNORE_DUPS
|
||||
setopt HIST_IGNORE_SPACE
|
||||
setopt SHARE_HISTORY
|
||||
setopt EXTENDED_HISTORY
|
||||
|
||||
setopt EXTENDED_GLOB
|
||||
|
||||
WORDCHARS=''
|
||||
|
||||
FZF_ALT_C_OPTS=--walker=dir,follow
|
84
.config/zsh/aliases/docker.zsh
Normal file
84
.config/zsh/aliases/docker.zsh
Normal file
@ -0,0 +1,84 @@
|
||||
alias dk='docker'
|
||||
|
||||
## container
|
||||
alias dkc='docker container' \
|
||||
dkcc='docker container create' \
|
||||
dkci='docker container inspect' \
|
||||
dkcls='docker container ls' \
|
||||
dkclsa='docker container ls -a' \
|
||||
dkclsaq='docker container ls -a -q' \
|
||||
dkclsq='docker container ls -q' \
|
||||
dkcrm!='docker container rm -f' \
|
||||
dkcrm='docker container rm' \
|
||||
dkcsp='docker container stop' \
|
||||
dkcst='docker container restart' \
|
||||
dkex='docker container exec -i -t' \
|
||||
dklo='docker logs -f' \
|
||||
dkr='docker run -i -t' \
|
||||
dktop='docker top'
|
||||
|
||||
## image
|
||||
alias dkb='docker build . -t' \
|
||||
dki='docker image' \
|
||||
dkic='docker image create' \
|
||||
dkii='docker image inspect' \
|
||||
dkil='docker pull' \
|
||||
dkils='docker image ls' \
|
||||
dkilsa='docker image ls -a' \
|
||||
dkilsaq='docker image ls -a -q' \
|
||||
dkilsq='docker image ls -q' \
|
||||
dkip='docker image push' \
|
||||
dkirm!='docker image rm -f' \
|
||||
dkirm='docker image rm' \
|
||||
dkis='docker image save' \
|
||||
dkit='docker image tag'
|
||||
|
||||
## volume
|
||||
alias dkv='docker volume' \
|
||||
dkvc='docker volume create' \
|
||||
dkvi='docker volume inspect' \
|
||||
dkvls='docker volume ls' \
|
||||
dkvlsq='docker volume ls -q' \
|
||||
dkvrm!='docker volume rm -f' \
|
||||
dkvrm='docker volume rm'
|
||||
|
||||
## network
|
||||
alias dkn='docker network' \
|
||||
dknc='docker network create' \
|
||||
dkni='docker network inspect' \
|
||||
dknls='docker network ls' \
|
||||
dknlsq='docker network ls -q' \
|
||||
dknrm!='docker network rm -f' \
|
||||
dknrm='docker network rm'
|
||||
|
||||
## system
|
||||
alias dksys='docker system' \
|
||||
dksysdf='docker system df' \
|
||||
dksysp!='docker system prune -f' \
|
||||
dksysp='docker system prune'
|
||||
|
||||
# compose
|
||||
alias dc='docker-compose' \
|
||||
dcd='docker-compose down' \
|
||||
dcup='docker-compose up' \
|
||||
dcupb='docker-compose up --build' \
|
||||
dcupd='docker-compose up -d' \
|
||||
dcupdb='docker-compose up -d --build'
|
||||
|
||||
## container
|
||||
alias dccls='docker-compose ps' \
|
||||
dcclsq='docker-compose ps -q' \
|
||||
dcex='docker-compose exec' \
|
||||
dcr='docker-compose run --rm' \
|
||||
dcrd='docker-compose run -d --rm' \
|
||||
dcrm!='docker-compose rm -f' \
|
||||
dcrm='docker-compose rm' \
|
||||
dcrmv!='docker-compose rm -v -f' \
|
||||
dcrmv='docker-compose rm -v' \
|
||||
dcsp='docker-compose stop' \
|
||||
dcst='docker-compose restart'
|
||||
|
||||
## image
|
||||
alias dcb!='docker-compose build --no-cache' \
|
||||
dcb='docker-compose build' \
|
||||
dcl='docker-compose pull'
|
56
.config/zsh/aliases/general.zsh
Normal file
56
.config/zsh/aliases/general.zsh
Normal file
@ -0,0 +1,56 @@
|
||||
function update() {
|
||||
$TERM --hold -e "$SHELL" -ic "pac -Syu && echo -e '\e[32mDONE'" &
|
||||
$TERM --hold -e "$SHELL" -ic "flatpak update && echo -e '\e[32mDONE'" &
|
||||
$TERM --hold -e "$SHELL" -ic "config submodule update --remote --recursive && echo -e '\e[32mDONE'" &
|
||||
}
|
||||
|
||||
alias pac='sudo pacman'
|
||||
alias neofetch=fastfetch
|
||||
alias mail=aerc
|
||||
alias rss=newsraft
|
||||
|
||||
alias vi='$EDITOR'
|
||||
|
||||
alias qcp='qcp -o tabsize=4' \
|
||||
qmv='qmv -o tabsize=4'
|
||||
|
||||
alias config='git --git-dir="$HOME/.dotfiles/" --work-tree="$HOME"' \
|
||||
viconf='(cd "$XDG_CONFIG_HOME/nvim" && $EDITOR .)' \
|
||||
zconf='(cd "$ZDOTDIR/" && $EDITOR .) && . "$ZDOTDIR/.zshrc"'
|
||||
|
||||
alias ssh='TERM=xterm-256color ssh'
|
||||
|
||||
alias sudo='sudo ' \
|
||||
watch='watch -c ' \
|
||||
xargs='xargs '
|
||||
|
||||
function tmp() {
|
||||
cd "$(mktemp -d --tmpdir "$1"XXX)"
|
||||
}
|
||||
|
||||
alias -g ...='../..' \
|
||||
....='../../..' \
|
||||
.....='../../../..' \
|
||||
......='../../../../..'
|
||||
|
||||
alias cp='cp -vi' \
|
||||
mv='mv -vi' \
|
||||
rm='rm -vI' \
|
||||
mkdir='mkdir -v' \
|
||||
rsync='rsync -P'
|
||||
|
||||
alias ls='ls --color=auto' \
|
||||
ll='ls -lh' \
|
||||
l='ll -a' \
|
||||
la='ll -A'
|
||||
|
||||
alias diff='diff --color' \
|
||||
grep='grep --color --exclude-dir={.bzr,.cache,.git,.hg,.idea,.svn,.tox,.venv,.vscode,CVS,node_modules}'
|
||||
|
||||
alias feh='feh --auto-zoom --scale-down'
|
||||
|
||||
alias xmr='monero-wallet-cli --daemon-address monero.maby.dev:18081 --trusted-daemon --log-file=/tmp/monero-wallet-cli.log --wallet-file /home/ange/.config/monero/ange'
|
||||
|
||||
function bd() {
|
||||
echo - "$@" | base64 -d; echo
|
||||
}
|
247
.config/zsh/aliases/git.zsh
Normal file
247
.config/zsh/aliases/git.zsh
Normal file
@ -0,0 +1,247 @@
|
||||
function gi() {
|
||||
curl -fL https://www.toptal.com/developers/gitignore/api/"${(j:,:)@}"
|
||||
}
|
||||
|
||||
function current_branch() {
|
||||
git branch | awk '$1 == "*" {print $2}'
|
||||
}
|
||||
|
||||
function grename() {
|
||||
if [[ -z "$1" || -z "$2" ]]; then
|
||||
echo "Usage: $0 old_branch new_branch"
|
||||
return 1
|
||||
fi
|
||||
|
||||
# Rename branch locally
|
||||
git branch -m "$1" "$2"
|
||||
# Rename branch in origin remote
|
||||
if git push origin :"$1"; then
|
||||
git push --set-upstream origin "$2"
|
||||
fi
|
||||
}
|
||||
|
||||
alias ggpur='ggu' \
|
||||
g='git' \
|
||||
ga='git add' \
|
||||
gaa='git add --all' \
|
||||
gapa='git add --patch' \
|
||||
gau='git add --update' \
|
||||
gav='git add --verbose' \
|
||||
gam='git am' \
|
||||
gama='git am --abort' \
|
||||
gamc='git am --continue' \
|
||||
gamscp='git am --show-current-patch' \
|
||||
gams='git am --skip' \
|
||||
gap='git apply' \
|
||||
gapt='git apply --3way' \
|
||||
gbs='git bisect' \
|
||||
gbsb='git bisect bad' \
|
||||
gbsg='git bisect good' \
|
||||
gbsn='git bisect new' \
|
||||
gbso='git bisect old' \
|
||||
gbsr='git bisect reset' \
|
||||
gbss='git bisect start' \
|
||||
gbl='git blame -w' \
|
||||
gb='git branch' \
|
||||
gba='git branch --all' \
|
||||
gbd='git branch --delete' \
|
||||
gbD='git branch --delete --force'
|
||||
|
||||
alias gbgd='LANG=C git branch --no-color -vv | grep ": gone\]" | awk '"'"'{print $1}'"'"' | xargs git branch -d' \
|
||||
gbgD='LANG=C git branch --no-color -vv | grep ": gone\]" | awk '"'"'{print $1}'"'"' | xargs git branch -D' \
|
||||
gbm='git branch --move' \
|
||||
gbnm='git branch --no-merged' \
|
||||
gbr='git branch --remote' \
|
||||
ggsup='git branch --set-upstream-to=origin/$(current_branch)' \
|
||||
gbg='LANG=C git branch -vv | grep ": gone\]"' \
|
||||
gco='git checkout' \
|
||||
gcor='git checkout --recurse-submodules' \
|
||||
gcb='git checkout -b' \
|
||||
gcp='git cherry-pick' \
|
||||
gcpa='git cherry-pick --abort' \
|
||||
gcpc='git cherry-pick --continue' \
|
||||
gclean='git clean --interactive -d' \
|
||||
gcl='git clone --recurse-submodules'
|
||||
|
||||
function gccd() {
|
||||
gcl "$@" && cd "$(basename "$_")"
|
||||
}
|
||||
compdef _git gccd=git-clone
|
||||
|
||||
alias gcam='git commit --all --message' \
|
||||
gcas='git commit --all --signoff' \
|
||||
gcasm='git commit --all --signoff --message' \
|
||||
gcs='git commit --gpg-sign' \
|
||||
gcss='git commit --gpg-sign --signoff' \
|
||||
gcssm='git commit --gpg-sign --signoff --message' \
|
||||
gcmsg='git commit --message' \
|
||||
gcsm='git commit --signoff --message' \
|
||||
gc='git commit --verbose' \
|
||||
gca='git commit --verbose --all' \
|
||||
gca!='git commit --verbose --all --amend' \
|
||||
gcan!='git commit --verbose --all --no-edit --amend' \
|
||||
gcans!='git commit --verbose --all --signoff --no-edit --amend' \
|
||||
gc!='git commit --verbose --amend' \
|
||||
gcn!='git commit --verbose --no-edit --amend' \
|
||||
gcf='git config --list' \
|
||||
gdct='git describe --tags $(git rev-list --tags --max-count=1)' \
|
||||
gd='git diff' \
|
||||
gdca='git diff --cached' \
|
||||
gdcw='git diff --cached --word-diff' \
|
||||
gds='git diff --staged' \
|
||||
gdw='git diff --word-diff'
|
||||
|
||||
function gdv() {
|
||||
git diff -w "$@" | view -
|
||||
}
|
||||
compdef _git gdv=git-diff
|
||||
|
||||
alias gdup='git diff @{upstream}'
|
||||
|
||||
alias gdt='git diff-tree --no-commit-id --name-only -r' \
|
||||
gf='git fetch'
|
||||
# --jobs=<n> was added in git 2.8
|
||||
alias gfa='git fetch --all --prune --jobs=10' \
|
||||
gfo='git fetch origin' \
|
||||
gg='git gui citool' \
|
||||
gga='git gui citool --amend' \
|
||||
ghh='git help' \
|
||||
glgg='git log --graph' \
|
||||
glgga='git log --graph --decorate --all' \
|
||||
glgm='git log --graph --max-count=10' \
|
||||
glods='git log --graph --pretty="%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%ad) %C(bold blue)<%an>%Creset" --date=short' \
|
||||
glod='git log --graph --pretty="%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%ad) %C(bold blue)<%an>%Creset"' \
|
||||
glola='git log --graph --pretty="%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%ar) %C(bold blue)<%an>%Creset" --all' \
|
||||
glols='git log --graph --pretty="%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%ar) %C(bold blue)<%an>%Creset" --stat' \
|
||||
glol='git log --graph --pretty="%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%ar) %C(bold blue)<%an>%Creset"' \
|
||||
glo='git log --oneline --decorate' \
|
||||
glog='git log --oneline --decorate --graph' \
|
||||
gloga='git log --oneline --decorate --graph --all'
|
||||
|
||||
# Pretty log messages
|
||||
function _git_log_prettily() {
|
||||
if ! [ -z $1 ]; then
|
||||
git log --pretty=$1
|
||||
fi
|
||||
}
|
||||
compdef _git _git_log_prettily=git-log
|
||||
|
||||
alias glp='_git_log_prettily' \
|
||||
glg='git log --stat' \
|
||||
glgp='git log --stat --patch' \
|
||||
gignored='git ls-files -v | grep "^[[:lower:]]"' \
|
||||
gfg='git ls-files | grep' \
|
||||
gmr='git merge' \
|
||||
gmra='git merge --abort' \
|
||||
gmrs="git merge --squash" \
|
||||
gmrtl='git mergetool --no-prompt' \
|
||||
gmrtlvim='git mergetool --no-prompt --tool=vimdiff'
|
||||
|
||||
alias gl='git pull' \
|
||||
gpr='git pull --rebase' \
|
||||
gprv='git pull --rebase -v' \
|
||||
gpra='git pull --rebase --autostash' \
|
||||
gprav='git pull --rebase --autostash -v'
|
||||
|
||||
function ggu() {
|
||||
[[ "$#" != 1 ]] && local b="$(current_branch)"
|
||||
git pull --rebase origin "${b:=$1}"
|
||||
}
|
||||
compdef _git ggu=git-checkout
|
||||
|
||||
alias ggpull='git pull origin "$(current_branch)"'
|
||||
|
||||
function ggl() {
|
||||
if [[ "$#" != 0 ]] && [[ "$#" != 1 ]]; then
|
||||
git pull origin "${*}"
|
||||
else
|
||||
[[ "$#" == 0 ]] && local b="$(current_branch)"
|
||||
git pull origin "${b:=$1}"
|
||||
fi
|
||||
}
|
||||
compdef _git ggl=git-checkout
|
||||
|
||||
alias gluc='git pull upstream $(current_branch)' \
|
||||
gp='git push' \
|
||||
gpd='git push --dry-run'
|
||||
|
||||
function ggf() {
|
||||
[[ "$#" != 1 ]] && local b="$(current_branch)"
|
||||
git push --force origin "${b:=$1}"
|
||||
}
|
||||
compdef _git ggf=git-checkout
|
||||
|
||||
alias gpf!='git push --force' \
|
||||
gpf='git push --force-with-lease --force-if-includes'
|
||||
|
||||
function ggfl() {
|
||||
[[ "$#" != 1 ]] && local b="$(current_branch)"
|
||||
git push --force-with-lease origin "${b:=$1}"
|
||||
}
|
||||
compdef _git ggfl=git-checkout
|
||||
|
||||
alias gpsup='git push --set-upstream origin $(current_branch)' \
|
||||
gpsupf='git push --set-upstream origin $(current_branch) --force-with-lease --force-if-includes' \
|
||||
gpv='git push --verbose' \
|
||||
gpoat='git push origin --all && git push origin --tags' \
|
||||
gpod='git push origin --delete' \
|
||||
ggpush='git push origin "$(current_branch)"' \
|
||||
gpu='git push upstream' \
|
||||
grb='git rebase' \
|
||||
grba='git rebase --abort' \
|
||||
grbc='git rebase --continue' \
|
||||
grbi='git rebase --interactive' \
|
||||
grbo='git rebase --onto' \
|
||||
grbs='git rebase --skip' \
|
||||
gr='git remote' \
|
||||
grv='git remote --verbose' \
|
||||
gra='git remote add' \
|
||||
grrm='git remote remove' \
|
||||
grmv='git remote rename' \
|
||||
grset='git remote set-url' \
|
||||
grup='git remote update' \
|
||||
grh='git reset' \
|
||||
gru='git reset --' \
|
||||
grhh='git reset --hard' \
|
||||
grhk='git reset --keep' \
|
||||
grhs='git reset --soft' \
|
||||
gpristine='git reset --hard && git clean --force -dfx' \
|
||||
groh='git reset origin/$(current_branch) --hard' \
|
||||
grs='git restore' \
|
||||
grss='git restore --source' \
|
||||
grst='git restore --staged' \
|
||||
grev='git revert' \
|
||||
grm='git rm' \
|
||||
grmc='git rm --cached' \
|
||||
grt='cd "$(git rev-parse --show-toplevel || echo .)"' \
|
||||
gcount='git shortlog --summary --numbered' \
|
||||
gsh='git show' \
|
||||
gsps='git show --pretty=short --show-signature' \
|
||||
gstall='git stash --all' \
|
||||
gstaa='git stash apply' \
|
||||
gstc='git stash clear' \
|
||||
gstd='git stash drop' \
|
||||
gstl='git stash list' \
|
||||
gstp='git stash pop' \
|
||||
gsta='git stash push' \
|
||||
gsts='git stash show --patch' \
|
||||
gst='git status' \
|
||||
gss='git status --short' \
|
||||
gsb='git status --short --branch' \
|
||||
gsi='git submodule init' \
|
||||
gsu='git submodule update' \
|
||||
gsw='git switch' \
|
||||
gswc='git switch --create' \
|
||||
gta='git tag --annotate' \
|
||||
gts='git tag --sign' \
|
||||
gtv='git tag | sort -V' \
|
||||
gignore='git update-index --assume-unchanged' \
|
||||
gunignore='git update-index --no-assume-unchanged' \
|
||||
gwch='git whatchanged -p --abbrev-commit --pretty=medium' \
|
||||
gwt='git worktree' \
|
||||
gwta='git worktree add' \
|
||||
gwtls='git worktree list' \
|
||||
gwtmv='git worktree move' \
|
||||
gwtrm='git worktree remove' \
|
||||
gstu='gsta --include-untracked' \
|
||||
gtl='gtl(){ git tag --sort=-v:refname -n --list "${1}*" }; noglob gtl'
|
802
.config/zsh/aliases/kubectl.zsh
Normal file
802
.config/zsh/aliases/kubectl.zsh
Normal file
@ -0,0 +1,802 @@
|
||||
function kxn() {
|
||||
1="$(echo - "$1" | tr -c '[:alnum:]-_' '[ *]')"
|
||||
local ctx; ctx="$(awk '{print tolower($1)}' <<< "$1")"
|
||||
local ns; ns="${2-$(awk '{print tolower($2)}' <<< "$2")}"
|
||||
|
||||
kubectx "$ctx"
|
||||
[ -n "$ns" ] && kubens "$ns"
|
||||
}
|
||||
|
||||
alias kga='kubectl get "$(kubectl api-resources --verbs=list --namespaced -oname | grep -v event | paste -sd,)"' \
|
||||
kns='kubens' \
|
||||
\
|
||||
k='kubectl' \
|
||||
ksys='kubectl --namespace=kube-system' \
|
||||
ka='kubectl apply --recursive -f' \
|
||||
ksysa='kubectl --namespace=kube-system apply --recursive -f' \
|
||||
kak='kubectl apply -k' \
|
||||
kk='kubectl kustomize' \
|
||||
kex='kubectl exec -i -t' \
|
||||
ksysex='kubectl --namespace=kube-system exec -i -t' \
|
||||
klo='kubectl logs -f' \
|
||||
ksyslo='kubectl --namespace=kube-system logs -f' \
|
||||
klop='kubectl logs -f -p' \
|
||||
ksyslop='kubectl --namespace=kube-system logs -f -p' \
|
||||
kp='kubectl proxy' \
|
||||
kpf='kubectl port-forward' \
|
||||
kg='kubectl get' \
|
||||
ksysg='kubectl --namespace=kube-system get' \
|
||||
kd='kubectl describe' \
|
||||
ksysd='kubectl --namespace=kube-system describe' \
|
||||
krm='kubectl delete' \
|
||||
ksysrm='kubectl --namespace=kube-system delete' \
|
||||
krun='kubectl run --rm --restart=Never --image-pull-policy=IfNotPresent -i -t' \
|
||||
ksysrun='kubectl --namespace=kube-system run --rm --restart=Never --image-pull-policy=IfNotPresent -i -t' \
|
||||
kgpo='kubectl get pods' \
|
||||
ksysgpo='kubectl --namespace=kube-system get pods' \
|
||||
kdpo='kubectl describe pods' \
|
||||
ksysdpo='kubectl --namespace=kube-system describe pods' \
|
||||
krmpo='kubectl delete pods' \
|
||||
ksysrmpo='kubectl --namespace=kube-system delete pods' \
|
||||
kgdep='kubectl get deployment' \
|
||||
ksysgdep='kubectl --namespace=kube-system get deployment' \
|
||||
kddep='kubectl describe deployment' \
|
||||
ksysddep='kubectl --namespace=kube-system describe deployment' \
|
||||
krmdep='kubectl delete deployment' \
|
||||
ksysrmdep='kubectl --namespace=kube-system delete deployment' \
|
||||
kgsts='kubectl get statefulset' \
|
||||
ksysgsts='kubectl --namespace=kube-system get statefulset' \
|
||||
kdsts='kubectl describe statefulset' \
|
||||
ksysdsts='kubectl --namespace=kube-system describe statefulset' \
|
||||
krmsts='kubectl delete statefulset' \
|
||||
ksysrmsts='kubectl --namespace=kube-system delete statefulset' \
|
||||
kgsvc='kubectl get service' \
|
||||
ksysgsvc='kubectl --namespace=kube-system get service' \
|
||||
kdsvc='kubectl describe service' \
|
||||
ksysdsvc='kubectl --namespace=kube-system describe service' \
|
||||
krmsvc='kubectl delete service' \
|
||||
ksysrmsvc='kubectl --namespace=kube-system delete service' \
|
||||
kging='kubectl get ingress' \
|
||||
ksysging='kubectl --namespace=kube-system get ingress' \
|
||||
kding='kubectl describe ingress' \
|
||||
ksysding='kubectl --namespace=kube-system describe ingress' \
|
||||
krming='kubectl delete ingress' \
|
||||
ksysrming='kubectl --namespace=kube-system delete ingress' \
|
||||
kgcm='kubectl get configmap' \
|
||||
ksysgcm='kubectl --namespace=kube-system get configmap' \
|
||||
kdcm='kubectl describe configmap' \
|
||||
ksysdcm='kubectl --namespace=kube-system describe configmap' \
|
||||
krmcm='kubectl delete configmap' \
|
||||
ksysrmcm='kubectl --namespace=kube-system delete configmap' \
|
||||
kgsec='kubectl get secret' \
|
||||
ksysgsec='kubectl --namespace=kube-system get secret' \
|
||||
kdsec='kubectl describe secret' \
|
||||
ksysdsec='kubectl --namespace=kube-system describe secret' \
|
||||
krmsec='kubectl delete secret' \
|
||||
ksysrmsec='kubectl --namespace=kube-system delete secret' \
|
||||
kgno='kubectl get nodes' \
|
||||
kdno='kubectl describe nodes' \
|
||||
kgns='kubectl get namespaces' \
|
||||
kdns='kubectl describe namespaces' \
|
||||
krmns='kubectl delete namespaces' \
|
||||
kgoyaml='kubectl get -o=yaml' \
|
||||
ksysgoyaml='kubectl --namespace=kube-system get -o=yaml' \
|
||||
kgpooyaml='kubectl get pods -o=yaml' \
|
||||
ksysgpooyaml='kubectl --namespace=kube-system get pods -o=yaml' \
|
||||
kgdepoyaml='kubectl get deployment -o=yaml' \
|
||||
ksysgdepoyaml='kubectl --namespace=kube-system get deployment -o=yaml' \
|
||||
kgstsoyaml='kubectl get statefulset -o=yaml' \
|
||||
ksysgstsoyaml='kubectl --namespace=kube-system get statefulset -o=yaml' \
|
||||
kgsvcoyaml='kubectl get service -o=yaml' \
|
||||
ksysgsvcoyaml='kubectl --namespace=kube-system get service -o=yaml' \
|
||||
kgingoyaml='kubectl get ingress -o=yaml' \
|
||||
ksysgingoyaml='kubectl --namespace=kube-system get ingress -o=yaml' \
|
||||
kgcmoyaml='kubectl get configmap -o=yaml' \
|
||||
ksysgcmoyaml='kubectl --namespace=kube-system get configmap -o=yaml' \
|
||||
kgsecoyaml='kubectl get secret -o=yaml' \
|
||||
ksysgsecoyaml='kubectl --namespace=kube-system get secret -o=yaml' \
|
||||
kgnooyaml='kubectl get nodes -o=yaml' \
|
||||
kgnsoyaml='kubectl get namespaces -o=yaml' \
|
||||
kgowide='kubectl get -o=wide' \
|
||||
ksysgowide='kubectl --namespace=kube-system get -o=wide' \
|
||||
kgpoowide='kubectl get pods -o=wide' \
|
||||
ksysgpoowide='kubectl --namespace=kube-system get pods -o=wide' \
|
||||
kgdepowide='kubectl get deployment -o=wide' \
|
||||
ksysgdepowide='kubectl --namespace=kube-system get deployment -o=wide' \
|
||||
kgstsowide='kubectl get statefulset -o=wide' \
|
||||
ksysgstsowide='kubectl --namespace=kube-system get statefulset -o=wide' \
|
||||
kgsvcowide='kubectl get service -o=wide' \
|
||||
ksysgsvcowide='kubectl --namespace=kube-system get service -o=wide' \
|
||||
kgingowide='kubectl get ingress -o=wide' \
|
||||
ksysgingowide='kubectl --namespace=kube-system get ingress -o=wide' \
|
||||
kgcmowide='kubectl get configmap -o=wide' \
|
||||
ksysgcmowide='kubectl --namespace=kube-system get configmap -o=wide' \
|
||||
kgsecowide='kubectl get secret -o=wide' \
|
||||
ksysgsecowide='kubectl --namespace=kube-system get secret -o=wide' \
|
||||
kgnoowide='kubectl get nodes -o=wide' \
|
||||
kgnsowide='kubectl get namespaces -o=wide' \
|
||||
kgojson='kubectl get -o=json' \
|
||||
ksysgojson='kubectl --namespace=kube-system get -o=json' \
|
||||
kgpoojson='kubectl get pods -o=json' \
|
||||
ksysgpoojson='kubectl --namespace=kube-system get pods -o=json' \
|
||||
kgdepojson='kubectl get deployment -o=json' \
|
||||
ksysgdepojson='kubectl --namespace=kube-system get deployment -o=json' \
|
||||
kgstsojson='kubectl get statefulset -o=json' \
|
||||
ksysgstsojson='kubectl --namespace=kube-system get statefulset -o=json' \
|
||||
kgsvcojson='kubectl get service -o=json' \
|
||||
ksysgsvcojson='kubectl --namespace=kube-system get service -o=json' \
|
||||
kgingojson='kubectl get ingress -o=json' \
|
||||
ksysgingojson='kubectl --namespace=kube-system get ingress -o=json' \
|
||||
kgcmojson='kubectl get configmap -o=json' \
|
||||
ksysgcmojson='kubectl --namespace=kube-system get configmap -o=json' \
|
||||
kgsecojson='kubectl get secret -o=json' \
|
||||
ksysgsecojson='kubectl --namespace=kube-system get secret -o=json' \
|
||||
kgnoojson='kubectl get nodes -o=json' \
|
||||
kgnsojson='kubectl get namespaces -o=json' \
|
||||
kgall='kubectl get --all-namespaces' \
|
||||
kdall='kubectl describe --all-namespaces' \
|
||||
kgpoall='kubectl get pods --all-namespaces' \
|
||||
kdpoall='kubectl describe pods --all-namespaces' \
|
||||
kgdepall='kubectl get deployment --all-namespaces' \
|
||||
kddepall='kubectl describe deployment --all-namespaces' \
|
||||
kgstsall='kubectl get statefulset --all-namespaces' \
|
||||
kdstsall='kubectl describe statefulset --all-namespaces' \
|
||||
kgsvcall='kubectl get service --all-namespaces' \
|
||||
kdsvcall='kubectl describe service --all-namespaces' \
|
||||
kgingall='kubectl get ingress --all-namespaces' \
|
||||
kdingall='kubectl describe ingress --all-namespaces' \
|
||||
kgcmall='kubectl get configmap --all-namespaces' \
|
||||
kdcmall='kubectl describe configmap --all-namespaces' \
|
||||
kgsecall='kubectl get secret --all-namespaces' \
|
||||
kdsecall='kubectl describe secret --all-namespaces' \
|
||||
kgnsall='kubectl get namespaces --all-namespaces' \
|
||||
kdnsall='kubectl describe namespaces --all-namespaces' \
|
||||
kgsl='kubectl get --show-labels' \
|
||||
ksysgsl='kubectl --namespace=kube-system get --show-labels' \
|
||||
kgposl='kubectl get pods --show-labels' \
|
||||
ksysgposl='kubectl --namespace=kube-system get pods --show-labels' \
|
||||
kgdepsl='kubectl get deployment --show-labels' \
|
||||
ksysgdepsl='kubectl --namespace=kube-system get deployment --show-labels' \
|
||||
kgstssl='kubectl get statefulset --show-labels' \
|
||||
ksysgstssl='kubectl --namespace=kube-system get statefulset --show-labels' \
|
||||
kgsvcsl='kubectl get service --show-labels' \
|
||||
ksysgsvcsl='kubectl --namespace=kube-system get service --show-labels' \
|
||||
kgingsl='kubectl get ingress --show-labels' \
|
||||
ksysgingsl='kubectl --namespace=kube-system get ingress --show-labels' \
|
||||
kgcmsl='kubectl get configmap --show-labels' \
|
||||
ksysgcmsl='kubectl --namespace=kube-system get configmap --show-labels' \
|
||||
kgsecsl='kubectl get secret --show-labels' \
|
||||
ksysgsecsl='kubectl --namespace=kube-system get secret --show-labels' \
|
||||
kgnosl='kubectl get nodes --show-labels' \
|
||||
kgnssl='kubectl get namespaces --show-labels' \
|
||||
krmall='kubectl delete --all' \
|
||||
ksysrmall='kubectl --namespace=kube-system delete --all' \
|
||||
krmpoall='kubectl delete pods --all' \
|
||||
ksysrmpoall='kubectl --namespace=kube-system delete pods --all' \
|
||||
krmdepall='kubectl delete deployment --all' \
|
||||
ksysrmdepall='kubectl --namespace=kube-system delete deployment --all' \
|
||||
krmstsall='kubectl delete statefulset --all' \
|
||||
ksysrmstsall='kubectl --namespace=kube-system delete statefulset --all' \
|
||||
krmsvcall='kubectl delete service --all' \
|
||||
ksysrmsvcall='kubectl --namespace=kube-system delete service --all' \
|
||||
krmingall='kubectl delete ingress --all' \
|
||||
ksysrmingall='kubectl --namespace=kube-system delete ingress --all' \
|
||||
krmcmall='kubectl delete configmap --all' \
|
||||
ksysrmcmall='kubectl --namespace=kube-system delete configmap --all' \
|
||||
krmsecall='kubectl delete secret --all' \
|
||||
ksysrmsecall='kubectl --namespace=kube-system delete secret --all' \
|
||||
krmnsall='kubectl delete namespaces --all' \
|
||||
kgw='kubectl get --watch' \
|
||||
ksysgw='kubectl --namespace=kube-system get --watch' \
|
||||
kgpow='kubectl get pods --watch' \
|
||||
ksysgpow='kubectl --namespace=kube-system get pods --watch' \
|
||||
kgdepw='kubectl get deployment --watch' \
|
||||
ksysgdepw='kubectl --namespace=kube-system get deployment --watch' \
|
||||
kgstsw='kubectl get statefulset --watch' \
|
||||
ksysgstsw='kubectl --namespace=kube-system get statefulset --watch' \
|
||||
kgsvcw='kubectl get service --watch' \
|
||||
ksysgsvcw='kubectl --namespace=kube-system get service --watch' \
|
||||
kgingw='kubectl get ingress --watch' \
|
||||
ksysgingw='kubectl --namespace=kube-system get ingress --watch' \
|
||||
kgcmw='kubectl get configmap --watch' \
|
||||
ksysgcmw='kubectl --namespace=kube-system get configmap --watch' \
|
||||
kgsecw='kubectl get secret --watch' \
|
||||
ksysgsecw='kubectl --namespace=kube-system get secret --watch' \
|
||||
kgnow='kubectl get nodes --watch' \
|
||||
kgnsw='kubectl get namespaces --watch' \
|
||||
kgoyamlall='kubectl get -o=yaml --all-namespaces' \
|
||||
kgpooyamlall='kubectl get pods -o=yaml --all-namespaces' \
|
||||
kgdepoyamlall='kubectl get deployment -o=yaml --all-namespaces' \
|
||||
kgstsoyamlall='kubectl get statefulset -o=yaml --all-namespaces' \
|
||||
kgsvcoyamlall='kubectl get service -o=yaml --all-namespaces' \
|
||||
kgingoyamlall='kubectl get ingress -o=yaml --all-namespaces' \
|
||||
kgcmoyamlall='kubectl get configmap -o=yaml --all-namespaces' \
|
||||
kgsecoyamlall='kubectl get secret -o=yaml --all-namespaces' \
|
||||
kgnsoyamlall='kubectl get namespaces -o=yaml --all-namespaces' \
|
||||
kgalloyaml='kubectl get --all-namespaces -o=yaml' \
|
||||
kgpoalloyaml='kubectl get pods --all-namespaces -o=yaml' \
|
||||
kgdepalloyaml='kubectl get deployment --all-namespaces -o=yaml' \
|
||||
kgstsalloyaml='kubectl get statefulset --all-namespaces -o=yaml' \
|
||||
kgsvcalloyaml='kubectl get service --all-namespaces -o=yaml' \
|
||||
kgingalloyaml='kubectl get ingress --all-namespaces -o=yaml' \
|
||||
kgcmalloyaml='kubectl get configmap --all-namespaces -o=yaml' \
|
||||
kgsecalloyaml='kubectl get secret --all-namespaces -o=yaml' \
|
||||
kgnsalloyaml='kubectl get namespaces --all-namespaces -o=yaml' \
|
||||
kgowideall='kubectl get -o=wide --all-namespaces' \
|
||||
kgpoowideall='kubectl get pods -o=wide --all-namespaces' \
|
||||
kgdepowideall='kubectl get deployment -o=wide --all-namespaces' \
|
||||
kgstsowideall='kubectl get statefulset -o=wide --all-namespaces' \
|
||||
kgsvcowideall='kubectl get service -o=wide --all-namespaces' \
|
||||
kgingowideall='kubectl get ingress -o=wide --all-namespaces' \
|
||||
kgcmowideall='kubectl get configmap -o=wide --all-namespaces' \
|
||||
kgsecowideall='kubectl get secret -o=wide --all-namespaces' \
|
||||
kgnsowideall='kubectl get namespaces -o=wide --all-namespaces' \
|
||||
kgallowide='kubectl get --all-namespaces -o=wide' \
|
||||
kgpoallowide='kubectl get pods --all-namespaces -o=wide' \
|
||||
kgdepallowide='kubectl get deployment --all-namespaces -o=wide' \
|
||||
kgstsallowide='kubectl get statefulset --all-namespaces -o=wide' \
|
||||
kgsvcallowide='kubectl get service --all-namespaces -o=wide' \
|
||||
kgingallowide='kubectl get ingress --all-namespaces -o=wide' \
|
||||
kgcmallowide='kubectl get configmap --all-namespaces -o=wide' \
|
||||
kgsecallowide='kubectl get secret --all-namespaces -o=wide' \
|
||||
kgnsallowide='kubectl get namespaces --all-namespaces -o=wide' \
|
||||
kgowidesl='kubectl get -o=wide --show-labels' \
|
||||
ksysgowidesl='kubectl --namespace=kube-system get -o=wide --show-labels' \
|
||||
kgpoowidesl='kubectl get pods -o=wide --show-labels' \
|
||||
ksysgpoowidesl='kubectl --namespace=kube-system get pods -o=wide --show-labels' \
|
||||
kgdepowidesl='kubectl get deployment -o=wide --show-labels' \
|
||||
ksysgdepowidesl='kubectl --namespace=kube-system get deployment -o=wide --show-labels' \
|
||||
kgstsowidesl='kubectl get statefulset -o=wide --show-labels' \
|
||||
ksysgstsowidesl='kubectl --namespace=kube-system get statefulset -o=wide --show-labels' \
|
||||
kgsvcowidesl='kubectl get service -o=wide --show-labels' \
|
||||
ksysgsvcowidesl='kubectl --namespace=kube-system get service -o=wide --show-labels' \
|
||||
kgingowidesl='kubectl get ingress -o=wide --show-labels' \
|
||||
ksysgingowidesl='kubectl --namespace=kube-system get ingress -o=wide --show-labels' \
|
||||
kgcmowidesl='kubectl get configmap -o=wide --show-labels' \
|
||||
ksysgcmowidesl='kubectl --namespace=kube-system get configmap -o=wide --show-labels' \
|
||||
kgsecowidesl='kubectl get secret -o=wide --show-labels' \
|
||||
ksysgsecowidesl='kubectl --namespace=kube-system get secret -o=wide --show-labels' \
|
||||
kgnoowidesl='kubectl get nodes -o=wide --show-labels' \
|
||||
kgnsowidesl='kubectl get namespaces -o=wide --show-labels' \
|
||||
kgslowide='kubectl get --show-labels -o=wide' \
|
||||
ksysgslowide='kubectl --namespace=kube-system get --show-labels -o=wide' \
|
||||
kgposlowide='kubectl get pods --show-labels -o=wide' \
|
||||
ksysgposlowide='kubectl --namespace=kube-system get pods --show-labels -o=wide' \
|
||||
kgdepslowide='kubectl get deployment --show-labels -o=wide' \
|
||||
ksysgdepslowide='kubectl --namespace=kube-system get deployment --show-labels -o=wide' \
|
||||
kgstsslowide='kubectl get statefulset --show-labels -o=wide' \
|
||||
ksysgstsslowide='kubectl --namespace=kube-system get statefulset --show-labels -o=wide' \
|
||||
kgsvcslowide='kubectl get service --show-labels -o=wide' \
|
||||
ksysgsvcslowide='kubectl --namespace=kube-system get service --show-labels -o=wide' \
|
||||
kgingslowide='kubectl get ingress --show-labels -o=wide' \
|
||||
ksysgingslowide='kubectl --namespace=kube-system get ingress --show-labels -o=wide' \
|
||||
kgcmslowide='kubectl get configmap --show-labels -o=wide' \
|
||||
ksysgcmslowide='kubectl --namespace=kube-system get configmap --show-labels -o=wide' \
|
||||
kgsecslowide='kubectl get secret --show-labels -o=wide' \
|
||||
ksysgsecslowide='kubectl --namespace=kube-system get secret --show-labels -o=wide' \
|
||||
kgnoslowide='kubectl get nodes --show-labels -o=wide' \
|
||||
kgnsslowide='kubectl get namespaces --show-labels -o=wide' \
|
||||
kgojsonall='kubectl get -o=json --all-namespaces' \
|
||||
kgpoojsonall='kubectl get pods -o=json --all-namespaces' \
|
||||
kgdepojsonall='kubectl get deployment -o=json --all-namespaces' \
|
||||
kgstsojsonall='kubectl get statefulset -o=json --all-namespaces' \
|
||||
kgsvcojsonall='kubectl get service -o=json --all-namespaces' \
|
||||
kgingojsonall='kubectl get ingress -o=json --all-namespaces' \
|
||||
kgcmojsonall='kubectl get configmap -o=json --all-namespaces' \
|
||||
kgsecojsonall='kubectl get secret -o=json --all-namespaces' \
|
||||
kgnsojsonall='kubectl get namespaces -o=json --all-namespaces' \
|
||||
kgallojson='kubectl get --all-namespaces -o=json' \
|
||||
kgpoallojson='kubectl get pods --all-namespaces -o=json' \
|
||||
kgdepallojson='kubectl get deployment --all-namespaces -o=json' \
|
||||
kgstsallojson='kubectl get statefulset --all-namespaces -o=json' \
|
||||
kgsvcallojson='kubectl get service --all-namespaces -o=json' \
|
||||
kgingallojson='kubectl get ingress --all-namespaces -o=json' \
|
||||
kgcmallojson='kubectl get configmap --all-namespaces -o=json' \
|
||||
kgsecallojson='kubectl get secret --all-namespaces -o=json' \
|
||||
kgnsallojson='kubectl get namespaces --all-namespaces -o=json' \
|
||||
kgallsl='kubectl get --all-namespaces --show-labels' \
|
||||
kgpoallsl='kubectl get pods --all-namespaces --show-labels' \
|
||||
kgdepallsl='kubectl get deployment --all-namespaces --show-labels' \
|
||||
kgstsallsl='kubectl get statefulset --all-namespaces --show-labels' \
|
||||
kgsvcallsl='kubectl get service --all-namespaces --show-labels' \
|
||||
kgingallsl='kubectl get ingress --all-namespaces --show-labels' \
|
||||
kgcmallsl='kubectl get configmap --all-namespaces --show-labels' \
|
||||
kgsecallsl='kubectl get secret --all-namespaces --show-labels' \
|
||||
kgnsallsl='kubectl get namespaces --all-namespaces --show-labels' \
|
||||
kgslall='kubectl get --show-labels --all-namespaces' \
|
||||
kgposlall='kubectl get pods --show-labels --all-namespaces' \
|
||||
kgdepslall='kubectl get deployment --show-labels --all-namespaces' \
|
||||
kgstsslall='kubectl get statefulset --show-labels --all-namespaces' \
|
||||
kgsvcslall='kubectl get service --show-labels --all-namespaces' \
|
||||
kgingslall='kubectl get ingress --show-labels --all-namespaces' \
|
||||
kgcmslall='kubectl get configmap --show-labels --all-namespaces' \
|
||||
kgsecslall='kubectl get secret --show-labels --all-namespaces' \
|
||||
kgnsslall='kubectl get namespaces --show-labels --all-namespaces' \
|
||||
kgallw='kubectl get --all-namespaces --watch' \
|
||||
kgpoallw='kubectl get pods --all-namespaces --watch' \
|
||||
kgdepallw='kubectl get deployment --all-namespaces --watch' \
|
||||
kgstsallw='kubectl get statefulset --all-namespaces --watch' \
|
||||
kgsvcallw='kubectl get service --all-namespaces --watch' \
|
||||
kgingallw='kubectl get ingress --all-namespaces --watch' \
|
||||
kgcmallw='kubectl get configmap --all-namespaces --watch' \
|
||||
kgsecallw='kubectl get secret --all-namespaces --watch' \
|
||||
kgnsallw='kubectl get namespaces --all-namespaces --watch' \
|
||||
kgwall='kubectl get --watch --all-namespaces' \
|
||||
kgpowall='kubectl get pods --watch --all-namespaces' \
|
||||
kgdepwall='kubectl get deployment --watch --all-namespaces' \
|
||||
kgstswall='kubectl get statefulset --watch --all-namespaces' \
|
||||
kgsvcwall='kubectl get service --watch --all-namespaces' \
|
||||
kgingwall='kubectl get ingress --watch --all-namespaces' \
|
||||
kgcmwall='kubectl get configmap --watch --all-namespaces' \
|
||||
kgsecwall='kubectl get secret --watch --all-namespaces' \
|
||||
kgnswall='kubectl get namespaces --watch --all-namespaces' \
|
||||
kgslw='kubectl get --show-labels --watch' \
|
||||
ksysgslw='kubectl --namespace=kube-system get --show-labels --watch' \
|
||||
kgposlw='kubectl get pods --show-labels --watch' \
|
||||
ksysgposlw='kubectl --namespace=kube-system get pods --show-labels --watch' \
|
||||
kgdepslw='kubectl get deployment --show-labels --watch' \
|
||||
ksysgdepslw='kubectl --namespace=kube-system get deployment --show-labels --watch' \
|
||||
kgstsslw='kubectl get statefulset --show-labels --watch' \
|
||||
ksysgstsslw='kubectl --namespace=kube-system get statefulset --show-labels --watch' \
|
||||
kgsvcslw='kubectl get service --show-labels --watch' \
|
||||
ksysgsvcslw='kubectl --namespace=kube-system get service --show-labels --watch' \
|
||||
kgingslw='kubectl get ingress --show-labels --watch' \
|
||||
ksysgingslw='kubectl --namespace=kube-system get ingress --show-labels --watch' \
|
||||
kgcmslw='kubectl get configmap --show-labels --watch' \
|
||||
ksysgcmslw='kubectl --namespace=kube-system get configmap --show-labels --watch' \
|
||||
kgsecslw='kubectl get secret --show-labels --watch' \
|
||||
ksysgsecslw='kubectl --namespace=kube-system get secret --show-labels --watch' \
|
||||
kgnoslw='kubectl get nodes --show-labels --watch' \
|
||||
kgnsslw='kubectl get namespaces --show-labels --watch' \
|
||||
kgwsl='kubectl get --watch --show-labels' \
|
||||
ksysgwsl='kubectl --namespace=kube-system get --watch --show-labels' \
|
||||
kgpowsl='kubectl get pods --watch --show-labels' \
|
||||
ksysgpowsl='kubectl --namespace=kube-system get pods --watch --show-labels' \
|
||||
kgdepwsl='kubectl get deployment --watch --show-labels' \
|
||||
ksysgdepwsl='kubectl --namespace=kube-system get deployment --watch --show-labels' \
|
||||
kgstswsl='kubectl get statefulset --watch --show-labels' \
|
||||
ksysgstswsl='kubectl --namespace=kube-system get statefulset --watch --show-labels' \
|
||||
kgsvcwsl='kubectl get service --watch --show-labels' \
|
||||
ksysgsvcwsl='kubectl --namespace=kube-system get service --watch --show-labels' \
|
||||
kgingwsl='kubectl get ingress --watch --show-labels' \
|
||||
ksysgingwsl='kubectl --namespace=kube-system get ingress --watch --show-labels' \
|
||||
kgcmwsl='kubectl get configmap --watch --show-labels' \
|
||||
ksysgcmwsl='kubectl --namespace=kube-system get configmap --watch --show-labels' \
|
||||
kgsecwsl='kubectl get secret --watch --show-labels' \
|
||||
ksysgsecwsl='kubectl --namespace=kube-system get secret --watch --show-labels' \
|
||||
kgnowsl='kubectl get nodes --watch --show-labels' \
|
||||
kgnswsl='kubectl get namespaces --watch --show-labels' \
|
||||
kgowideallsl='kubectl get -o=wide --all-namespaces --show-labels' \
|
||||
kgpoowideallsl='kubectl get pods -o=wide --all-namespaces --show-labels' \
|
||||
kgdepowideallsl='kubectl get deployment -o=wide --all-namespaces --show-labels' \
|
||||
kgstsowideallsl='kubectl get statefulset -o=wide --all-namespaces --show-labels' \
|
||||
kgsvcowideallsl='kubectl get service -o=wide --all-namespaces --show-labels' \
|
||||
kgingowideallsl='kubectl get ingress -o=wide --all-namespaces --show-labels' \
|
||||
kgcmowideallsl='kubectl get configmap -o=wide --all-namespaces --show-labels' \
|
||||
kgsecowideallsl='kubectl get secret -o=wide --all-namespaces --show-labels' \
|
||||
kgnsowideallsl='kubectl get namespaces -o=wide --all-namespaces --show-labels' \
|
||||
kgowideslall='kubectl get -o=wide --show-labels --all-namespaces' \
|
||||
kgpoowideslall='kubectl get pods -o=wide --show-labels --all-namespaces' \
|
||||
kgdepowideslall='kubectl get deployment -o=wide --show-labels --all-namespaces' \
|
||||
kgstsowideslall='kubectl get statefulset -o=wide --show-labels --all-namespaces' \
|
||||
kgsvcowideslall='kubectl get service -o=wide --show-labels --all-namespaces' \
|
||||
kgingowideslall='kubectl get ingress -o=wide --show-labels --all-namespaces' \
|
||||
kgcmowideslall='kubectl get configmap -o=wide --show-labels --all-namespaces' \
|
||||
kgsecowideslall='kubectl get secret -o=wide --show-labels --all-namespaces' \
|
||||
kgnsowideslall='kubectl get namespaces -o=wide --show-labels --all-namespaces' \
|
||||
kgallowidesl='kubectl get --all-namespaces -o=wide --show-labels' \
|
||||
kgpoallowidesl='kubectl get pods --all-namespaces -o=wide --show-labels' \
|
||||
kgdepallowidesl='kubectl get deployment --all-namespaces -o=wide --show-labels' \
|
||||
kgstsallowidesl='kubectl get statefulset --all-namespaces -o=wide --show-labels' \
|
||||
kgsvcallowidesl='kubectl get service --all-namespaces -o=wide --show-labels' \
|
||||
kgingallowidesl='kubectl get ingress --all-namespaces -o=wide --show-labels' \
|
||||
kgcmallowidesl='kubectl get configmap --all-namespaces -o=wide --show-labels' \
|
||||
kgsecallowidesl='kubectl get secret --all-namespaces -o=wide --show-labels' \
|
||||
kgnsallowidesl='kubectl get namespaces --all-namespaces -o=wide --show-labels' \
|
||||
kgallslowide='kubectl get --all-namespaces --show-labels -o=wide' \
|
||||
kgpoallslowide='kubectl get pods --all-namespaces --show-labels -o=wide' \
|
||||
kgdepallslowide='kubectl get deployment --all-namespaces --show-labels -o=wide' \
|
||||
kgstsallslowide='kubectl get statefulset --all-namespaces --show-labels -o=wide' \
|
||||
kgsvcallslowide='kubectl get service --all-namespaces --show-labels -o=wide' \
|
||||
kgingallslowide='kubectl get ingress --all-namespaces --show-labels -o=wide' \
|
||||
kgcmallslowide='kubectl get configmap --all-namespaces --show-labels -o=wide' \
|
||||
kgsecallslowide='kubectl get secret --all-namespaces --show-labels -o=wide' \
|
||||
kgnsallslowide='kubectl get namespaces --all-namespaces --show-labels -o=wide' \
|
||||
kgslowideall='kubectl get --show-labels -o=wide --all-namespaces' \
|
||||
kgposlowideall='kubectl get pods --show-labels -o=wide --all-namespaces' \
|
||||
kgdepslowideall='kubectl get deployment --show-labels -o=wide --all-namespaces' \
|
||||
kgstsslowideall='kubectl get statefulset --show-labels -o=wide --all-namespaces' \
|
||||
kgsvcslowideall='kubectl get service --show-labels -o=wide --all-namespaces' \
|
||||
kgingslowideall='kubectl get ingress --show-labels -o=wide --all-namespaces' \
|
||||
kgcmslowideall='kubectl get configmap --show-labels -o=wide --all-namespaces' \
|
||||
kgsecslowideall='kubectl get secret --show-labels -o=wide --all-namespaces' \
|
||||
kgnsslowideall='kubectl get namespaces --show-labels -o=wide --all-namespaces' \
|
||||
kgslallowide='kubectl get --show-labels --all-namespaces -o=wide' \
|
||||
kgposlallowide='kubectl get pods --show-labels --all-namespaces -o=wide' \
|
||||
kgdepslallowide='kubectl get deployment --show-labels --all-namespaces -o=wide' \
|
||||
kgstsslallowide='kubectl get statefulset --show-labels --all-namespaces -o=wide' \
|
||||
kgsvcslallowide='kubectl get service --show-labels --all-namespaces -o=wide' \
|
||||
kgingslallowide='kubectl get ingress --show-labels --all-namespaces -o=wide' \
|
||||
kgcmslallowide='kubectl get configmap --show-labels --all-namespaces -o=wide' \
|
||||
kgsecslallowide='kubectl get secret --show-labels --all-namespaces -o=wide' \
|
||||
kgnsslallowide='kubectl get namespaces --show-labels --all-namespaces -o=wide' \
|
||||
kgallslw='kubectl get --all-namespaces --show-labels --watch' \
|
||||
kgpoallslw='kubectl get pods --all-namespaces --show-labels --watch' \
|
||||
kgdepallslw='kubectl get deployment --all-namespaces --show-labels --watch' \
|
||||
kgstsallslw='kubectl get statefulset --all-namespaces --show-labels --watch' \
|
||||
kgsvcallslw='kubectl get service --all-namespaces --show-labels --watch' \
|
||||
kgingallslw='kubectl get ingress --all-namespaces --show-labels --watch' \
|
||||
kgcmallslw='kubectl get configmap --all-namespaces --show-labels --watch' \
|
||||
kgsecallslw='kubectl get secret --all-namespaces --show-labels --watch' \
|
||||
kgnsallslw='kubectl get namespaces --all-namespaces --show-labels --watch' \
|
||||
kgallwsl='kubectl get --all-namespaces --watch --show-labels' \
|
||||
kgpoallwsl='kubectl get pods --all-namespaces --watch --show-labels' \
|
||||
kgdepallwsl='kubectl get deployment --all-namespaces --watch --show-labels' \
|
||||
kgstsallwsl='kubectl get statefulset --all-namespaces --watch --show-labels' \
|
||||
kgsvcallwsl='kubectl get service --all-namespaces --watch --show-labels' \
|
||||
kgingallwsl='kubectl get ingress --all-namespaces --watch --show-labels' \
|
||||
kgcmallwsl='kubectl get configmap --all-namespaces --watch --show-labels' \
|
||||
kgsecallwsl='kubectl get secret --all-namespaces --watch --show-labels' \
|
||||
kgnsallwsl='kubectl get namespaces --all-namespaces --watch --show-labels' \
|
||||
kgslallw='kubectl get --show-labels --all-namespaces --watch' \
|
||||
kgposlallw='kubectl get pods --show-labels --all-namespaces --watch' \
|
||||
kgdepslallw='kubectl get deployment --show-labels --all-namespaces --watch' \
|
||||
kgstsslallw='kubectl get statefulset --show-labels --all-namespaces --watch' \
|
||||
kgsvcslallw='kubectl get service --show-labels --all-namespaces --watch' \
|
||||
kgingslallw='kubectl get ingress --show-labels --all-namespaces --watch' \
|
||||
kgcmslallw='kubectl get configmap --show-labels --all-namespaces --watch' \
|
||||
kgsecslallw='kubectl get secret --show-labels --all-namespaces --watch' \
|
||||
kgnsslallw='kubectl get namespaces --show-labels --all-namespaces --watch' \
|
||||
kgslwall='kubectl get --show-labels --watch --all-namespaces' \
|
||||
kgposlwall='kubectl get pods --show-labels --watch --all-namespaces' \
|
||||
kgdepslwall='kubectl get deployment --show-labels --watch --all-namespaces' \
|
||||
kgstsslwall='kubectl get statefulset --show-labels --watch --all-namespaces' \
|
||||
kgsvcslwall='kubectl get service --show-labels --watch --all-namespaces' \
|
||||
kgingslwall='kubectl get ingress --show-labels --watch --all-namespaces' \
|
||||
kgcmslwall='kubectl get configmap --show-labels --watch --all-namespaces' \
|
||||
kgsecslwall='kubectl get secret --show-labels --watch --all-namespaces' \
|
||||
kgnsslwall='kubectl get namespaces --show-labels --watch --all-namespaces' \
|
||||
kgwallsl='kubectl get --watch --all-namespaces --show-labels' \
|
||||
kgpowallsl='kubectl get pods --watch --all-namespaces --show-labels' \
|
||||
kgdepwallsl='kubectl get deployment --watch --all-namespaces --show-labels' \
|
||||
kgstswallsl='kubectl get statefulset --watch --all-namespaces --show-labels' \
|
||||
kgsvcwallsl='kubectl get service --watch --all-namespaces --show-labels' \
|
||||
kgingwallsl='kubectl get ingress --watch --all-namespaces --show-labels' \
|
||||
kgcmwallsl='kubectl get configmap --watch --all-namespaces --show-labels' \
|
||||
kgsecwallsl='kubectl get secret --watch --all-namespaces --show-labels' \
|
||||
kgnswallsl='kubectl get namespaces --watch --all-namespaces --show-labels' \
|
||||
kgwslall='kubectl get --watch --show-labels --all-namespaces' \
|
||||
kgpowslall='kubectl get pods --watch --show-labels --all-namespaces' \
|
||||
kgdepwslall='kubectl get deployment --watch --show-labels --all-namespaces' \
|
||||
kgstswslall='kubectl get statefulset --watch --show-labels --all-namespaces' \
|
||||
kgsvcwslall='kubectl get service --watch --show-labels --all-namespaces' \
|
||||
kgingwslall='kubectl get ingress --watch --show-labels --all-namespaces' \
|
||||
kgcmwslall='kubectl get configmap --watch --show-labels --all-namespaces' \
|
||||
kgsecwslall='kubectl get secret --watch --show-labels --all-namespaces' \
|
||||
kgnswslall='kubectl get namespaces --watch --show-labels --all-namespaces' \
|
||||
kgf='kubectl get --recursive -f' \
|
||||
kdf='kubectl describe --recursive -f' \
|
||||
krmf='kubectl delete --recursive -f' \
|
||||
kgoyamlf='kubectl get -o=yaml --recursive -f' \
|
||||
kgowidef='kubectl get -o=wide --recursive -f' \
|
||||
kgojsonf='kubectl get -o=json --recursive -f' \
|
||||
kgslf='kubectl get --show-labels --recursive -f' \
|
||||
kgwf='kubectl get --watch --recursive -f' \
|
||||
kgowideslf='kubectl get -o=wide --show-labels --recursive -f' \
|
||||
kgslowidef='kubectl get --show-labels -o=wide --recursive -f' \
|
||||
kgslwf='kubectl get --show-labels --watch --recursive -f' \
|
||||
kgwslf='kubectl get --watch --show-labels --recursive -f' \
|
||||
kgl='kubectl get -l' \
|
||||
ksysgl='kubectl --namespace=kube-system get -l' \
|
||||
kdl='kubectl describe -l' \
|
||||
ksysdl='kubectl --namespace=kube-system describe -l' \
|
||||
krml='kubectl delete -l' \
|
||||
ksysrml='kubectl --namespace=kube-system delete -l' \
|
||||
kgpol='kubectl get pods -l' \
|
||||
ksysgpol='kubectl --namespace=kube-system get pods -l' \
|
||||
kdpol='kubectl describe pods -l' \
|
||||
ksysdpol='kubectl --namespace=kube-system describe pods -l' \
|
||||
krmpol='kubectl delete pods -l' \
|
||||
ksysrmpol='kubectl --namespace=kube-system delete pods -l' \
|
||||
kgdepl='kubectl get deployment -l' \
|
||||
ksysgdepl='kubectl --namespace=kube-system get deployment -l' \
|
||||
kddepl='kubectl describe deployment -l' \
|
||||
ksysddepl='kubectl --namespace=kube-system describe deployment -l' \
|
||||
krmdepl='kubectl delete deployment -l' \
|
||||
ksysrmdepl='kubectl --namespace=kube-system delete deployment -l' \
|
||||
kgstsl='kubectl get statefulset -l' \
|
||||
ksysgstsl='kubectl --namespace=kube-system get statefulset -l' \
|
||||
kdstsl='kubectl describe statefulset -l' \
|
||||
ksysdstsl='kubectl --namespace=kube-system describe statefulset -l' \
|
||||
krmstsl='kubectl delete statefulset -l' \
|
||||
ksysrmstsl='kubectl --namespace=kube-system delete statefulset -l' \
|
||||
kgsvcl='kubectl get service -l' \
|
||||
ksysgsvcl='kubectl --namespace=kube-system get service -l' \
|
||||
kdsvcl='kubectl describe service -l' \
|
||||
ksysdsvcl='kubectl --namespace=kube-system describe service -l' \
|
||||
krmsvcl='kubectl delete service -l' \
|
||||
ksysrmsvcl='kubectl --namespace=kube-system delete service -l' \
|
||||
kgingl='kubectl get ingress -l' \
|
||||
ksysgingl='kubectl --namespace=kube-system get ingress -l' \
|
||||
kdingl='kubectl describe ingress -l' \
|
||||
ksysdingl='kubectl --namespace=kube-system describe ingress -l' \
|
||||
krmingl='kubectl delete ingress -l' \
|
||||
ksysrmingl='kubectl --namespace=kube-system delete ingress -l' \
|
||||
kgcml='kubectl get configmap -l' \
|
||||
ksysgcml='kubectl --namespace=kube-system get configmap -l' \
|
||||
kdcml='kubectl describe configmap -l' \
|
||||
ksysdcml='kubectl --namespace=kube-system describe configmap -l' \
|
||||
krmcml='kubectl delete configmap -l' \
|
||||
ksysrmcml='kubectl --namespace=kube-system delete configmap -l' \
|
||||
kgsecl='kubectl get secret -l' \
|
||||
ksysgsecl='kubectl --namespace=kube-system get secret -l' \
|
||||
kdsecl='kubectl describe secret -l' \
|
||||
ksysdsecl='kubectl --namespace=kube-system describe secret -l' \
|
||||
krmsecl='kubectl delete secret -l' \
|
||||
ksysrmsecl='kubectl --namespace=kube-system delete secret -l' \
|
||||
kgnol='kubectl get nodes -l' \
|
||||
kdnol='kubectl describe nodes -l' \
|
||||
kgnsl='kubectl get namespaces -l' \
|
||||
kdnsl='kubectl describe namespaces -l' \
|
||||
krmnsl='kubectl delete namespaces -l' \
|
||||
kgoyamll='kubectl get -o=yaml -l' \
|
||||
ksysgoyamll='kubectl --namespace=kube-system get -o=yaml -l' \
|
||||
kgpooyamll='kubectl get pods -o=yaml -l' \
|
||||
ksysgpooyamll='kubectl --namespace=kube-system get pods -o=yaml -l' \
|
||||
kgdepoyamll='kubectl get deployment -o=yaml -l' \
|
||||
ksysgdepoyamll='kubectl --namespace=kube-system get deployment -o=yaml -l' \
|
||||
kgstsoyamll='kubectl get statefulset -o=yaml -l' \
|
||||
ksysgstsoyamll='kubectl --namespace=kube-system get statefulset -o=yaml -l' \
|
||||
kgsvcoyamll='kubectl get service -o=yaml -l' \
|
||||
ksysgsvcoyamll='kubectl --namespace=kube-system get service -o=yaml -l' \
|
||||
kgingoyamll='kubectl get ingress -o=yaml -l' \
|
||||
ksysgingoyamll='kubectl --namespace=kube-system get ingress -o=yaml -l' \
|
||||
kgcmoyamll='kubectl get configmap -o=yaml -l' \
|
||||
ksysgcmoyamll='kubectl --namespace=kube-system get configmap -o=yaml -l' \
|
||||
kgsecoyamll='kubectl get secret -o=yaml -l' \
|
||||
ksysgsecoyamll='kubectl --namespace=kube-system get secret -o=yaml -l' \
|
||||
kgnooyamll='kubectl get nodes -o=yaml -l' \
|
||||
kgnsoyamll='kubectl get namespaces -o=yaml -l' \
|
||||
kgowidel='kubectl get -o=wide -l' \
|
||||
ksysgowidel='kubectl --namespace=kube-system get -o=wide -l' \
|
||||
kgpoowidel='kubectl get pods -o=wide -l' \
|
||||
ksysgpoowidel='kubectl --namespace=kube-system get pods -o=wide -l' \
|
||||
kgdepowidel='kubectl get deployment -o=wide -l' \
|
||||
ksysgdepowidel='kubectl --namespace=kube-system get deployment -o=wide -l' \
|
||||
kgstsowidel='kubectl get statefulset -o=wide -l' \
|
||||
ksysgstsowidel='kubectl --namespace=kube-system get statefulset -o=wide -l' \
|
||||
kgsvcowidel='kubectl get service -o=wide -l' \
|
||||
ksysgsvcowidel='kubectl --namespace=kube-system get service -o=wide -l' \
|
||||
kgingowidel='kubectl get ingress -o=wide -l' \
|
||||
ksysgingowidel='kubectl --namespace=kube-system get ingress -o=wide -l' \
|
||||
kgcmowidel='kubectl get configmap -o=wide -l' \
|
||||
ksysgcmowidel='kubectl --namespace=kube-system get configmap -o=wide -l' \
|
||||
kgsecowidel='kubectl get secret -o=wide -l' \
|
||||
ksysgsecowidel='kubectl --namespace=kube-system get secret -o=wide -l' \
|
||||
kgnoowidel='kubectl get nodes -o=wide -l' \
|
||||
kgnsowidel='kubectl get namespaces -o=wide -l' \
|
||||
kgojsonl='kubectl get -o=json -l' \
|
||||
ksysgojsonl='kubectl --namespace=kube-system get -o=json -l' \
|
||||
kgpoojsonl='kubectl get pods -o=json -l' \
|
||||
ksysgpoojsonl='kubectl --namespace=kube-system get pods -o=json -l' \
|
||||
kgdepojsonl='kubectl get deployment -o=json -l' \
|
||||
ksysgdepojsonl='kubectl --namespace=kube-system get deployment -o=json -l' \
|
||||
kgstsojsonl='kubectl get statefulset -o=json -l' \
|
||||
ksysgstsojsonl='kubectl --namespace=kube-system get statefulset -o=json -l' \
|
||||
kgsvcojsonl='kubectl get service -o=json -l' \
|
||||
ksysgsvcojsonl='kubectl --namespace=kube-system get service -o=json -l' \
|
||||
kgingojsonl='kubectl get ingress -o=json -l' \
|
||||
ksysgingojsonl='kubectl --namespace=kube-system get ingress -o=json -l' \
|
||||
kgcmojsonl='kubectl get configmap -o=json -l' \
|
||||
ksysgcmojsonl='kubectl --namespace=kube-system get configmap -o=json -l' \
|
||||
kgsecojsonl='kubectl get secret -o=json -l' \
|
||||
ksysgsecojsonl='kubectl --namespace=kube-system get secret -o=json -l' \
|
||||
kgnoojsonl='kubectl get nodes -o=json -l' \
|
||||
kgnsojsonl='kubectl get namespaces -o=json -l' \
|
||||
kgsll='kubectl get --show-labels -l' \
|
||||
ksysgsll='kubectl --namespace=kube-system get --show-labels -l' \
|
||||
kgposll='kubectl get pods --show-labels -l' \
|
||||
ksysgposll='kubectl --namespace=kube-system get pods --show-labels -l' \
|
||||
kgdepsll='kubectl get deployment --show-labels -l' \
|
||||
ksysgdepsll='kubectl --namespace=kube-system get deployment --show-labels -l' \
|
||||
kgstssll='kubectl get statefulset --show-labels -l' \
|
||||
ksysgstssll='kubectl --namespace=kube-system get statefulset --show-labels -l' \
|
||||
kgsvcsll='kubectl get service --show-labels -l' \
|
||||
ksysgsvcsll='kubectl --namespace=kube-system get service --show-labels -l' \
|
||||
kgingsll='kubectl get ingress --show-labels -l' \
|
||||
ksysgingsll='kubectl --namespace=kube-system get ingress --show-labels -l' \
|
||||
kgcmsll='kubectl get configmap --show-labels -l' \
|
||||
ksysgcmsll='kubectl --namespace=kube-system get configmap --show-labels -l' \
|
||||
kgsecsll='kubectl get secret --show-labels -l' \
|
||||
ksysgsecsll='kubectl --namespace=kube-system get secret --show-labels -l' \
|
||||
kgnosll='kubectl get nodes --show-labels -l' \
|
||||
kgnssll='kubectl get namespaces --show-labels -l' \
|
||||
kgwl='kubectl get --watch -l' \
|
||||
ksysgwl='kubectl --namespace=kube-system get --watch -l' \
|
||||
kgpowl='kubectl get pods --watch -l' \
|
||||
ksysgpowl='kubectl --namespace=kube-system get pods --watch -l' \
|
||||
kgdepwl='kubectl get deployment --watch -l' \
|
||||
ksysgdepwl='kubectl --namespace=kube-system get deployment --watch -l' \
|
||||
kgstswl='kubectl get statefulset --watch -l' \
|
||||
ksysgstswl='kubectl --namespace=kube-system get statefulset --watch -l' \
|
||||
kgsvcwl='kubectl get service --watch -l' \
|
||||
ksysgsvcwl='kubectl --namespace=kube-system get service --watch -l' \
|
||||
kgingwl='kubectl get ingress --watch -l' \
|
||||
ksysgingwl='kubectl --namespace=kube-system get ingress --watch -l' \
|
||||
kgcmwl='kubectl get configmap --watch -l' \
|
||||
ksysgcmwl='kubectl --namespace=kube-system get configmap --watch -l' \
|
||||
kgsecwl='kubectl get secret --watch -l' \
|
||||
ksysgsecwl='kubectl --namespace=kube-system get secret --watch -l' \
|
||||
kgnowl='kubectl get nodes --watch -l' \
|
||||
kgnswl='kubectl get namespaces --watch -l' \
|
||||
kgowidesll='kubectl get -o=wide --show-labels -l' \
|
||||
ksysgowidesll='kubectl --namespace=kube-system get -o=wide --show-labels -l' \
|
||||
kgpoowidesll='kubectl get pods -o=wide --show-labels -l' \
|
||||
ksysgpoowidesll='kubectl --namespace=kube-system get pods -o=wide --show-labels -l' \
|
||||
kgdepowidesll='kubectl get deployment -o=wide --show-labels -l' \
|
||||
ksysgdepowidesll='kubectl --namespace=kube-system get deployment -o=wide --show-labels -l' \
|
||||
kgstsowidesll='kubectl get statefulset -o=wide --show-labels -l' \
|
||||
ksysgstsowidesll='kubectl --namespace=kube-system get statefulset -o=wide --show-labels -l' \
|
||||
kgsvcowidesll='kubectl get service -o=wide --show-labels -l' \
|
||||
ksysgsvcowidesll='kubectl --namespace=kube-system get service -o=wide --show-labels -l' \
|
||||
kgingowidesll='kubectl get ingress -o=wide --show-labels -l' \
|
||||
ksysgingowidesll='kubectl --namespace=kube-system get ingress -o=wide --show-labels -l' \
|
||||
kgcmowidesll='kubectl get configmap -o=wide --show-labels -l' \
|
||||
ksysgcmowidesll='kubectl --namespace=kube-system get configmap -o=wide --show-labels -l' \
|
||||
kgsecowidesll='kubectl get secret -o=wide --show-labels -l' \
|
||||
ksysgsecowidesll='kubectl --namespace=kube-system get secret -o=wide --show-labels -l' \
|
||||
kgnoowidesll='kubectl get nodes -o=wide --show-labels -l' \
|
||||
kgnsowidesll='kubectl get namespaces -o=wide --show-labels -l' \
|
||||
kgslowidel='kubectl get --show-labels -o=wide -l' \
|
||||
ksysgslowidel='kubectl --namespace=kube-system get --show-labels -o=wide -l' \
|
||||
kgposlowidel='kubectl get pods --show-labels -o=wide -l' \
|
||||
ksysgposlowidel='kubectl --namespace=kube-system get pods --show-labels -o=wide -l' \
|
||||
kgdepslowidel='kubectl get deployment --show-labels -o=wide -l' \
|
||||
ksysgdepslowidel='kubectl --namespace=kube-system get deployment --show-labels -o=wide -l' \
|
||||
kgstsslowidel='kubectl get statefulset --show-labels -o=wide -l' \
|
||||
ksysgstsslowidel='kubectl --namespace=kube-system get statefulset --show-labels -o=wide -l' \
|
||||
kgsvcslowidel='kubectl get service --show-labels -o=wide -l' \
|
||||
ksysgsvcslowidel='kubectl --namespace=kube-system get service --show-labels -o=wide -l' \
|
||||
kgingslowidel='kubectl get ingress --show-labels -o=wide -l' \
|
||||
ksysgingslowidel='kubectl --namespace=kube-system get ingress --show-labels -o=wide -l' \
|
||||
kgcmslowidel='kubectl get configmap --show-labels -o=wide -l' \
|
||||
ksysgcmslowidel='kubectl --namespace=kube-system get configmap --show-labels -o=wide -l' \
|
||||
kgsecslowidel='kubectl get secret --show-labels -o=wide -l' \
|
||||
ksysgsecslowidel='kubectl --namespace=kube-system get secret --show-labels -o=wide -l' \
|
||||
kgnoslowidel='kubectl get nodes --show-labels -o=wide -l' \
|
||||
kgnsslowidel='kubectl get namespaces --show-labels -o=wide -l' \
|
||||
kgslwl='kubectl get --show-labels --watch -l' \
|
||||
ksysgslwl='kubectl --namespace=kube-system get --show-labels --watch -l' \
|
||||
kgposlwl='kubectl get pods --show-labels --watch -l' \
|
||||
ksysgposlwl='kubectl --namespace=kube-system get pods --show-labels --watch -l' \
|
||||
kgdepslwl='kubectl get deployment --show-labels --watch -l' \
|
||||
ksysgdepslwl='kubectl --namespace=kube-system get deployment --show-labels --watch -l' \
|
||||
kgstsslwl='kubectl get statefulset --show-labels --watch -l' \
|
||||
ksysgstsslwl='kubectl --namespace=kube-system get statefulset --show-labels --watch -l' \
|
||||
kgsvcslwl='kubectl get service --show-labels --watch -l' \
|
||||
ksysgsvcslwl='kubectl --namespace=kube-system get service --show-labels --watch -l' \
|
||||
kgingslwl='kubectl get ingress --show-labels --watch -l' \
|
||||
ksysgingslwl='kubectl --namespace=kube-system get ingress --show-labels --watch -l' \
|
||||
kgcmslwl='kubectl get configmap --show-labels --watch -l' \
|
||||
ksysgcmslwl='kubectl --namespace=kube-system get configmap --show-labels --watch -l' \
|
||||
kgsecslwl='kubectl get secret --show-labels --watch -l' \
|
||||
ksysgsecslwl='kubectl --namespace=kube-system get secret --show-labels --watch -l' \
|
||||
kgnoslwl='kubectl get nodes --show-labels --watch -l' \
|
||||
kgnsslwl='kubectl get namespaces --show-labels --watch -l' \
|
||||
kgwsll='kubectl get --watch --show-labels -l' \
|
||||
ksysgwsll='kubectl --namespace=kube-system get --watch --show-labels -l' \
|
||||
kgpowsll='kubectl get pods --watch --show-labels -l' \
|
||||
ksysgpowsll='kubectl --namespace=kube-system get pods --watch --show-labels -l' \
|
||||
kgdepwsll='kubectl get deployment --watch --show-labels -l' \
|
||||
ksysgdepwsll='kubectl --namespace=kube-system get deployment --watch --show-labels -l' \
|
||||
kgstswsll='kubectl get statefulset --watch --show-labels -l' \
|
||||
ksysgstswsll='kubectl --namespace=kube-system get statefulset --watch --show-labels -l' \
|
||||
kgsvcwsll='kubectl get service --watch --show-labels -l' \
|
||||
ksysgsvcwsll='kubectl --namespace=kube-system get service --watch --show-labels -l' \
|
||||
kgingwsll='kubectl get ingress --watch --show-labels -l' \
|
||||
ksysgingwsll='kubectl --namespace=kube-system get ingress --watch --show-labels -l' \
|
||||
kgcmwsll='kubectl get configmap --watch --show-labels -l' \
|
||||
ksysgcmwsll='kubectl --namespace=kube-system get configmap --watch --show-labels -l' \
|
||||
kgsecwsll='kubectl get secret --watch --show-labels -l' \
|
||||
ksysgsecwsll='kubectl --namespace=kube-system get secret --watch --show-labels -l' \
|
||||
kgnowsll='kubectl get nodes --watch --show-labels -l' \
|
||||
kgnswsll='kubectl get namespaces --watch --show-labels -l' \
|
||||
kexn='kubectl exec -i -t --namespace' \
|
||||
klon='kubectl logs -f --namespace' \
|
||||
kpfn='kubectl port-forward --namespace' \
|
||||
kgn='kubectl get --namespace' \
|
||||
kdn='kubectl describe --namespace' \
|
||||
krmn='kubectl delete --namespace' \
|
||||
kgpon='kubectl get pods --namespace' \
|
||||
kdpon='kubectl describe pods --namespace' \
|
||||
krmpon='kubectl delete pods --namespace' \
|
||||
kgdepn='kubectl get deployment --namespace' \
|
||||
kddepn='kubectl describe deployment --namespace' \
|
||||
krmdepn='kubectl delete deployment --namespace' \
|
||||
kgstsn='kubectl get statefulset --namespace' \
|
||||
kdstsn='kubectl describe statefulset --namespace' \
|
||||
krmstsn='kubectl delete statefulset --namespace' \
|
||||
kgsvcn='kubectl get service --namespace' \
|
||||
kdsvcn='kubectl describe service --namespace' \
|
||||
krmsvcn='kubectl delete service --namespace' \
|
||||
kgingn='kubectl get ingress --namespace' \
|
||||
kdingn='kubectl describe ingress --namespace' \
|
||||
krmingn='kubectl delete ingress --namespace' \
|
||||
kgcmn='kubectl get configmap --namespace' \
|
||||
kdcmn='kubectl describe configmap --namespace' \
|
||||
krmcmn='kubectl delete configmap --namespace' \
|
||||
kgsecn='kubectl get secret --namespace' \
|
||||
kdsecn='kubectl describe secret --namespace' \
|
||||
krmsecn='kubectl delete secret --namespace' \
|
||||
kgoyamln='kubectl get -o=yaml --namespace' \
|
||||
kgpooyamln='kubectl get pods -o=yaml --namespace' \
|
||||
kgdepoyamln='kubectl get deployment -o=yaml --namespace' \
|
||||
kgstsoyamln='kubectl get statefulset -o=yaml --namespace' \
|
||||
kgsvcoyamln='kubectl get service -o=yaml --namespace' \
|
||||
kgingoyamln='kubectl get ingress -o=yaml --namespace' \
|
||||
kgcmoyamln='kubectl get configmap -o=yaml --namespace' \
|
||||
kgsecoyamln='kubectl get secret -o=yaml --namespace' \
|
||||
kgowiden='kubectl get -o=wide --namespace' \
|
||||
kgpoowiden='kubectl get pods -o=wide --namespace' \
|
||||
kgdepowiden='kubectl get deployment -o=wide --namespace' \
|
||||
kgstsowiden='kubectl get statefulset -o=wide --namespace' \
|
||||
kgsvcowiden='kubectl get service -o=wide --namespace' \
|
||||
kgingowiden='kubectl get ingress -o=wide --namespace' \
|
||||
kgcmowiden='kubectl get configmap -o=wide --namespace' \
|
||||
kgsecowiden='kubectl get secret -o=wide --namespace' \
|
||||
kgojsonn='kubectl get -o=json --namespace' \
|
||||
kgpoojsonn='kubectl get pods -o=json --namespace' \
|
||||
kgdepojsonn='kubectl get deployment -o=json --namespace' \
|
||||
kgstsojsonn='kubectl get statefulset -o=json --namespace' \
|
||||
kgsvcojsonn='kubectl get service -o=json --namespace' \
|
||||
kgingojsonn='kubectl get ingress -o=json --namespace' \
|
||||
kgcmojsonn='kubectl get configmap -o=json --namespace' \
|
||||
kgsecojsonn='kubectl get secret -o=json --namespace' \
|
||||
kgsln='kubectl get --show-labels --namespace' \
|
||||
kgposln='kubectl get pods --show-labels --namespace' \
|
||||
kgdepsln='kubectl get deployment --show-labels --namespace' \
|
||||
kgstssln='kubectl get statefulset --show-labels --namespace' \
|
||||
kgsvcsln='kubectl get service --show-labels --namespace' \
|
||||
kgingsln='kubectl get ingress --show-labels --namespace' \
|
||||
kgcmsln='kubectl get configmap --show-labels --namespace' \
|
||||
kgsecsln='kubectl get secret --show-labels --namespace' \
|
||||
kgwn='kubectl get --watch --namespace' \
|
||||
kgpown='kubectl get pods --watch --namespace' \
|
||||
kgdepwn='kubectl get deployment --watch --namespace' \
|
||||
kgstswn='kubectl get statefulset --watch --namespace' \
|
||||
kgsvcwn='kubectl get service --watch --namespace' \
|
||||
kgingwn='kubectl get ingress --watch --namespace' \
|
||||
kgcmwn='kubectl get configmap --watch --namespace' \
|
||||
kgsecwn='kubectl get secret --watch --namespace' \
|
||||
kgowidesln='kubectl get -o=wide --show-labels --namespace' \
|
||||
kgpoowidesln='kubectl get pods -o=wide --show-labels --namespace' \
|
||||
kgdepowidesln='kubectl get deployment -o=wide --show-labels --namespace' \
|
||||
kgstsowidesln='kubectl get statefulset -o=wide --show-labels --namespace' \
|
||||
kgsvcowidesln='kubectl get service -o=wide --show-labels --namespace' \
|
||||
kgingowidesln='kubectl get ingress -o=wide --show-labels --namespace' \
|
||||
kgcmowidesln='kubectl get configmap -o=wide --show-labels --namespace' \
|
||||
kgsecowidesln='kubectl get secret -o=wide --show-labels --namespace' \
|
||||
kgslowiden='kubectl get --show-labels -o=wide --namespace' \
|
||||
kgposlowiden='kubectl get pods --show-labels -o=wide --namespace' \
|
||||
kgdepslowiden='kubectl get deployment --show-labels -o=wide --namespace' \
|
||||
kgstsslowiden='kubectl get statefulset --show-labels -o=wide --namespace' \
|
||||
kgsvcslowiden='kubectl get service --show-labels -o=wide --namespace' \
|
||||
kgingslowiden='kubectl get ingress --show-labels -o=wide --namespace' \
|
||||
kgcmslowiden='kubectl get configmap --show-labels -o=wide --namespace' \
|
||||
kgsecslowiden='kubectl get secret --show-labels -o=wide --namespace' \
|
||||
kgslwn='kubectl get --show-labels --watch --namespace' \
|
||||
kgposlwn='kubectl get pods --show-labels --watch --namespace' \
|
||||
kgdepslwn='kubectl get deployment --show-labels --watch --namespace' \
|
||||
kgstsslwn='kubectl get statefulset --show-labels --watch --namespace' \
|
||||
kgsvcslwn='kubectl get service --show-labels --watch --namespace' \
|
||||
kgingslwn='kubectl get ingress --show-labels --watch --namespace' \
|
||||
kgcmslwn='kubectl get configmap --show-labels --watch --namespace' \
|
||||
kgsecslwn='kubectl get secret --show-labels --watch --namespace' \
|
||||
kgwsln='kubectl get --watch --show-labels --namespace' \
|
||||
kgpowsln='kubectl get pods --watch --show-labels --namespace' \
|
||||
kgdepwsln='kubectl get deployment --watch --show-labels --namespace' \
|
||||
kgstswsln='kubectl get statefulset --watch --show-labels --namespace' \
|
||||
kgsvcwsln='kubectl get service --watch --show-labels --namespace' \
|
||||
kgingwsln='kubectl get ingress --watch --show-labels --namespace' \
|
||||
kgcmwsln='kubectl get configmap --watch --show-labels --namespace' \
|
||||
kgsecwsln='kubectl get secret --watch --show-labels --namespace'
|
10
.config/zsh/completions/_gi
Normal file
10
.config/zsh/completions/_gi
Normal file
@ -0,0 +1,10 @@
|
||||
#compdef gi
|
||||
|
||||
_gitignoreio_get_command_list() {
|
||||
curl -sfL https://www.toptal.com/developers/gitignore/api/list | tr ',' '\n'
|
||||
}
|
||||
|
||||
_gi() {
|
||||
compset -P '*,'
|
||||
compadd -S '' `_gitignoreio_get_command_list`
|
||||
}
|
14
.config/zsh/completions/_kxn
Normal file
14
.config/zsh/completions/_kxn
Normal file
@ -0,0 +1,14 @@
|
||||
#compdef kxn
|
||||
|
||||
_kxn() {
|
||||
case "$#words" in
|
||||
2)
|
||||
_arguments "1: :(- $(kubectl config get-contexts -oname))"
|
||||
;;
|
||||
3)
|
||||
_arguments "2: :($(kubectl --context "${words[2]}" get namespaces -o=jsonpath='{range .items[*].metadata.name}{@}{"\n"}{end}'))"
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
}
|
35
.config/zsh/input.zsh
Normal file
35
.config/zsh/input.zsh
Normal file
@ -0,0 +1,35 @@
|
||||
if (( ${+terminfo[smkx]} )) && (( ${+terminfo[rmkx]} )); then
|
||||
function zle-line-init() { echoti smkx }; zle -N zle-line-init
|
||||
function zle-line-finish() { echoti rmkx }; zle -N zle-line-finish
|
||||
fi
|
||||
|
||||
# Up/Down
|
||||
autoload -Uz up-line-or-beginning-search; zle -N up-line-or-beginning-search
|
||||
autoload -Uz down-line-or-beginning-search; zle -N down-line-or-beginning-search
|
||||
bindkey -- "${terminfo[kcuu1]}" up-line-or-beginning-search
|
||||
bindkey -- "${terminfo[kcud1]}" down-line-or-beginning-search
|
||||
|
||||
# Home/End
|
||||
(( ${+terminfo[khome]} )) && bindkey -- "${terminfo[khome]}" beginning-of-line
|
||||
(( ${+terminfo[kend]} )) && bindkey -- "${terminfo[kend]}" end-of-line
|
||||
|
||||
# Shift-Tab
|
||||
(( ${+terminfo[kcbt]} )) && bindkey -- "${terminfo[kcbt]}" reverse-menu-complete
|
||||
|
||||
# Delete
|
||||
(( ${+terminfo[kdch1]} )) && bindkey -- "${terminfo[kdch1]}" delete-char
|
||||
|
||||
# Ctrl-Delete
|
||||
(( "${+terminfo[kDC5]}" )) && bindkey -- "${terminfo[kDC5]}" kill-word
|
||||
|
||||
# Ctrl-RightArrow/LeftArrow
|
||||
(( "${+terminfo[kRIT5]}" )) && bindkey -- "${terminfo[kRIT5]}" forward-word
|
||||
(( "${+terminfo[kLFT5]}" )) && bindkey -- "${terminfo[kLFT5]}" backward-word
|
||||
|
||||
# Space - don't do history expansion
|
||||
bindkey ' ' magic-space
|
||||
|
||||
# vv in vi mode to edit cmd
|
||||
autoload -Uz edit-command-line
|
||||
zle -N edit-command-line
|
||||
bindkey -M vicmd 'vv' edit-command-line
|
74
.config/zsh/theme.zsh
Normal file
74
.config/zsh/theme.zsh
Normal file
@ -0,0 +1,74 @@
|
||||
autoload -Uz vcs_info colors && colors
|
||||
|
||||
VIRTUAL_ENV_DISABLE_PROMPT=1
|
||||
|
||||
export GROFF_NO_SGR=1
|
||||
export LESS_TERMCAP_mb="${fg_bold[red]}"
|
||||
export LESS_TERMCAP_md="${fg_bold[red]}"
|
||||
export LESS_TERMCAP_me="$reset_color"
|
||||
export LESS_TERMCAP_so="${fg_bold[yellow]}${bg[blue]}"
|
||||
export LESS_TERMCAP_se="$reset_color"
|
||||
export LESS_TERMCAP_us="${fg_bold[green]}"
|
||||
export LESS_TERMCAP_ue="$reset_color"
|
||||
|
||||
. <(dircolors)
|
||||
zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}"
|
||||
|
||||
zstyle ':completion:*:*:*:*:*' menu select
|
||||
zstyle ':completion:*' matcher-list 'r:|=*' 'l:|=* r:|=*'
|
||||
zstyle ':completion:*:*:kill:*:processes' list-colors '=(#b) #([0-9]#) ([0-9a-z-]#)*=01;34=0=01'
|
||||
zstyle ':completion:*:cd:*' tag-order local-directories directory-stack path-directories
|
||||
|
||||
|
||||
zstyle ':vcs_info:*' check-for-changes true
|
||||
zstyle ':vcs_info:*' stagedstr ' %{%F{178}%}+%{%f%b%}'
|
||||
zstyle ':vcs_info:*' unstagedstr ' %{%F{178}%}*%{%f%b%}'
|
||||
zstyle ':vcs_info:git:*' formats '%{%F{76}%}%b%{%f%}%c%u '
|
||||
zstyle ':vcs_info:git:*' actionformats '%{%F{76}%}%b%{%f%} %{%F{196}%}%a%{%f%}%c%u '
|
||||
|
||||
zstyle ':vcs_info:git*+set-message:*' hooks git-untracked
|
||||
function +vi-git-untracked(){
|
||||
if git status --porcelain | grep '??' &> /dev/null ; then
|
||||
hook_com[unstaged]+=' %{%F{39}%}?%{%f%b%}'
|
||||
fi
|
||||
}
|
||||
|
||||
function preexec() {
|
||||
PROMPT_timer="$SECONDS"
|
||||
}
|
||||
|
||||
function _get_time() {
|
||||
local d="$1"
|
||||
local text
|
||||
|
||||
text="$((d % 60))s"
|
||||
if [ "$d" -ge 60 ]; then
|
||||
(( d /= 60 ))
|
||||
text="$((d % 60))m$text"
|
||||
if [ "$d" -ge 60 ]; then
|
||||
(( d /= 60 ))
|
||||
text="${d}h$text"
|
||||
fi
|
||||
fi
|
||||
echo "$text"
|
||||
}
|
||||
|
||||
function precmd() {
|
||||
IFS='|' local ctx timer err="${pipestatus[*]}"
|
||||
|
||||
[ -n "$PROMPT_timer" ] && timer="$((SECONDS - PROMPT_timer))"
|
||||
unset -m 'PROMPT_*'
|
||||
|
||||
ctx="$(kubectx -c 2> /dev/null)"
|
||||
|
||||
vcs_info
|
||||
|
||||
[ -n "$ctx" ] && PROMPT_K8S="%{%F{134}%}$ctx/$(kubens -c)%{%f%b%} "
|
||||
[ "$timer" -ge 2 ] && PROMPT_TIMER="%{%F{101}%}$(_get_time "$timer")%{%f%b%} "
|
||||
[[ "$err" =~ [1-9] ]] && PROMPT_ERR="%{%F{160}%}$err%{%f%b%} "
|
||||
[ -n "$VIRTUAL_ENV" ] && PROMPT_VENV=" %{%F{37}%}${VIRTUAL_ENV:h:t}%{%f%b%}"
|
||||
}
|
||||
|
||||
setopt PROMPT_SUBST
|
||||
PROMPT='$PROMPT_K8S%{%B%F{32}%}%~%{%f%b%} $vcs_info_msg_0_$PROMPT_TIMER$PROMPT_ERR'
|
||||
RPROMPT='%{%F{71}%}%(1j.%j.)%{%f%b%}$PROMPT_VENV'
|
1
.inputrc
1
.inputrc
@ -1,5 +1,4 @@
|
||||
set colored-stats on
|
||||
set show-all-if-unmodified on
|
||||
|
||||
"\e[A":history-search-backward
|
||||
|
||||
|
@ -1 +0,0 @@
|
||||
complete -F _command doas
|
@ -1,6 +0,0 @@
|
||||
function _gi() {
|
||||
mapfile -t COMPREPLY < <(compgen -W \
|
||||
"$(curl -sfL https://www.toptal.com/developers/gitignore/api/list | tr ',' '\n')" \
|
||||
-- "${COMP_WORDS[1]}")
|
||||
}
|
||||
complete -F _gi gi
|
@ -1,2 +0,0 @@
|
||||
. /usr/share/bash-completion/completions/kubectl
|
||||
complete -F __start_kubectl k
|
@ -1,6 +0,0 @@
|
||||
function _kctx() {
|
||||
mapfile -t COMPREPLY < <(compgen -W \
|
||||
"$(kubectl config get-contexts -o name)" \
|
||||
-- "${COMP_WORDS[1]}")
|
||||
}
|
||||
complete -F _kctx kctx
|
@ -1,6 +0,0 @@
|
||||
function _kns() {
|
||||
mapfile -t COMPREPLY < <(compgen -W \
|
||||
"$(kubectl get namespace -o jsonpath='{..metadata.name}')" \
|
||||
-- "${COMP_WORDS[1]}")
|
||||
}
|
||||
complete -F _kns kns
|
37
.zshenv
Normal file
37
.zshenv
Normal file
@ -0,0 +1,37 @@
|
||||
export XDG_CACHE_HOME="$HOME/.cache"
|
||||
export XDG_CONFIG_HOME="$HOME/.config"
|
||||
export XDG_DATA_HOME="$HOME/.local/share"
|
||||
export XDG_STATE_HOME="$HOME/.local/state"
|
||||
export XDG_CONFIG_DIRS=/etc/xdg
|
||||
export XDG_DATA_DIRS="$XDG_DATA_HOME/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share:/usr/share"
|
||||
|
||||
export HISTSIZE=65536
|
||||
export SAVEHIST=8192
|
||||
|
||||
export HISTFILE="$XDG_STATE_HOME/zsh_history"
|
||||
export ZDOTDIR="$XDG_CONFIG_HOME/zsh"
|
||||
export LESSHISTFILE='-'
|
||||
|
||||
export KUBECONFIG="$XDG_CONFIG_HOME/kube"
|
||||
export KUBECACHEDIR="$XDG_CACHE_HOME/kube"
|
||||
|
||||
export PYTHON_HISTORY="$XDG_STATE_HOME/python_history"
|
||||
export PYTHONPYCACHEPREFIX="$XDG_CACHE_HOME/python"
|
||||
|
||||
export W3M_DIR="$XDG_STATE_HOME/w3m"
|
||||
|
||||
path=(
|
||||
"$HOME/.local/bin"
|
||||
"$XDG_DATA_HOME/flatpak/exports/bin"
|
||||
/var/lib/flatpak/exports/bin
|
||||
"$path"
|
||||
)
|
||||
|
||||
export BROWSER=org.mozilla.firefox
|
||||
export EDITOR=nvim
|
||||
export VISUAL=nvim
|
||||
export PAGER=less
|
||||
|
||||
export MAKEFLAGS='-j'
|
||||
|
||||
export DOCKER_HOST="unix://$XDG_RUNTIME_DIR/podman/podman.sock"
|
Loading…
Reference in New Issue
Block a user