💻 Tech
One technique for reusing shortcuts or aliases is to save them in a .sh file, then execute its contents in the current shell environment via source ./init.sh
. Sample file contents:
# init.sh
alias kn="k config set-context --current --namespace"
alias kd="k describe"
alias ka="k apply -f"
alias kr="k replace --force --grace-period=0 -f"
dryo="--dry-run=client -oyaml"