Compare commits
10 Commits
9e5fcc649e
...
08916f80b6
Author | SHA1 | Date | |
---|---|---|---|
|
08916f80b6 | ||
|
9324547f92 | ||
|
1c34023066 | ||
|
cd341b7d80 | ||
|
af5d43fb36 | ||
|
ddd9509d74 | ||
|
30597e31ed | ||
|
ebb0139dbe | ||
|
3759b1b0ac | ||
|
5f0ab15c42 |
5
aliases.d/bat
Normal file
5
aliases.d/bat
Normal file
@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
if (command -v bat &>/dev/null); then
|
||||
alias cat=bat
|
||||
fi
|
@ -6,10 +6,16 @@ if (command -v kubectl &>/dev/null); then
|
||||
alias k="kubectl"
|
||||
alias kg="kubectl get"
|
||||
alias kd="kubectl describe"
|
||||
|
||||
alias ks="kubectl --namespace kube-system"
|
||||
alias ksg="kubectl --namespace kube-system get"
|
||||
alias ksd="kubectl --namespace kube-system describe"
|
||||
alias kga="kubectl get --all-namespaces"
|
||||
alias kuc="kubectl config unset current-context"
|
||||
alias kun="kubectl config set-context --current --namespace="
|
||||
alias kgworkers="kubectl get nodes --selector '!node-role.kubernetes.io/control-plane' --label-columns heat,topology.kubernetes.io/zone,topology.kubernetes.io/region --sort-by metadata.labels.heat"
|
||||
|
||||
alias kgnodes="kubectl get nodes --label-columns topology.kubernetes.io/region,topology.kubernetes.io/zone"
|
||||
alias kgmasters="kubectl get nodes --selector 'node-role.kubernetes.io/control-plane' --label-columns topology.kubernetes.io/region,topology.kubernetes.io/zone"
|
||||
alias kgworkers="kubectl get nodes --selector '!node-role.kubernetes.io/control-plane' --label-columns topology.kubernetes.io/region,topology.kubernetes.io/zone"
|
||||
alias kgtaints="kubectl get nodes --output custom-columns=NAME:.metadata.name,TAINTS:.spec.taints"
|
||||
fi
|
||||
|
6
completion.d/flux
Normal file
6
completion.d/flux
Normal file
@ -0,0 +1,6 @@
|
||||
|
||||
#!/bin/bash
|
||||
|
||||
if (command -v flux &>/dev/null); then
|
||||
source <(flux completion bash)
|
||||
fi
|
5
completion.d/k3d
Normal file
5
completion.d/k3d
Normal file
@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
if (command -v k3d &>/dev/null); then
|
||||
source <(k3d completion bash)
|
||||
fi
|
5
completion.d/minikube
Normal file
5
completion.d/minikube
Normal file
@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
if (command -v minikube &>/dev/null); then
|
||||
source <(minikube completion bash)
|
||||
fi
|
@ -8,7 +8,9 @@ if (command -v nvim &>/dev/null); then
|
||||
fi
|
||||
|
||||
# PAGER
|
||||
export PAGER=less
|
||||
if (command -v less &>/dev/null); then
|
||||
export PAGER=less
|
||||
fi
|
||||
|
||||
# MANPAGER
|
||||
if (command -v nvim &>/dev/null); then
|
||||
@ -18,7 +20,11 @@ elif (command -v bat &>/dev/null); then
|
||||
fi
|
||||
|
||||
# TERMINAL
|
||||
export TERMINAL=kitty
|
||||
if (command -v kitty &>/dev/null); then
|
||||
export TERMINAL=kitty
|
||||
fi
|
||||
|
||||
# BROWSER
|
||||
export BROWSER=firefox
|
||||
if (command -v firefox &>/dev/null); then
|
||||
export BROWSER=firefox
|
||||
fi
|
||||
|
@ -1,6 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
if $(which keychain &> /dev/null)
|
||||
then
|
||||
eval $(keychain --agents ssh,gpg --eval)
|
||||
if (command -v keychain &>/dev/null); then
|
||||
eval "$(keychain --eval --noask ~/.ssh/{id_ed25519,id_rsa_native})"
|
||||
fi
|
||||
|
@ -4,7 +4,6 @@
|
||||
|
||||
# git clone https://github.com/riywo/anyenv $HOME/.anyenv
|
||||
|
||||
if ( which anyenv &> /dev/null )
|
||||
then
|
||||
if (which anyenv &>/dev/null); then
|
||||
eval "$(anyenv init -)"
|
||||
fi
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
if (which mcfly &>/dev/null); then
|
||||
export MCFLY_PROMPT="❯"
|
||||
if (command -v mcfly &>/dev/null); then
|
||||
export MCFLY_PROMPT="❯ "
|
||||
export MCFLY_INTERFACE_VIEW=BOTTOM
|
||||
export MCFLY_RESULTS=50
|
||||
export MCFLY_RESULTS_SORT=LAST_RUN
|
||||
|
16
rc.d/tmux
16
rc.d/tmux
@ -1,17 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
# GNU Screen stuff
|
||||
if ( which tmux &> /dev/null )
|
||||
then
|
||||
if [ $(pgrep -u "$UID" "tmux" | wc -l) -gt 0 ]
|
||||
then
|
||||
if [[ $TERM != screen* ]]
|
||||
then
|
||||
if (command -v tmux &>/dev/null); then
|
||||
if [ "$(pgrep -u "$UID" "tmux" | wc -l)" -gt 0 ]; then
|
||||
if [[ $TERM != screen* ]]; then
|
||||
nb_sessions=$(tmux list-session | wc -l)
|
||||
nb_sessions_attached=$(tmux list-session | grep "attached" | wc -l)
|
||||
nb_sessions_detached=$(tmux list-session | grep -v "attached" | wc -l)
|
||||
nb_sessions_attached=$(tmux list-session | grep -c "attached")
|
||||
nb_sessions_detached=$(tmux list-session | grep -c -v "attached")
|
||||
|
||||
echo_reverse "Found ${nb_sessions} tmux session(s)"
|
||||
echo_info "Found ${nb_sessions} tmux session(s)"
|
||||
|
||||
echo " * ${nb_sessions_attached} attached"
|
||||
tmux list-sessions | grep "attached" | sed -e 's/^/ - /'
|
||||
@ -22,4 +19,3 @@ then
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user