bash: psk --

This commit is contained in:
Michael Grote 2022-02-17 18:09:11 +01:00
parent 2dfabccd91
commit 65431d8c82

View file

@ -74,19 +74,19 @@ function m2m {
fi fi
fi fi
} }
function psk { #function psk {
if [[ "$1" == "--help" ]]; then # if [[ "$1" == "--help" ]]; then
echo "Beende Prozess "\$1"" # echo "Beende Prozess "\$1""
echo "" # echo ""
echo " Usage: psk <prozessname>" # echo " Usage: psk <prozessname>"
else # else
if [ -z "$1" ]; then # if [ -z "$1" ]; then
echo "[ERROR] Prozessname fehlt..." # echo "[ERROR] Prozessname fehlt..."
else # else
ps -ef | grep "$1" | grep -v grep | awk '{ print $2 }' | xargs kill -9 # ps -ef | grep "$1" | grep -v grep | awk '{ print $2 }' | xargs kill -9
fi # fi
fi # fi
} #}
function rgf { function rgf {
if [[ "$1" == "--help" ]]; then if [[ "$1" == "--help" ]]; then
echo "Finde alle Dateien die "\$1" im Namen haben." echo "Finde alle Dateien die "\$1" im Namen haben."
@ -177,6 +177,7 @@ alias grep="grep -i --color=auto"
alias hostname="hostname -f" alias hostname="hostname -f"
alias untar="tar -xzf" alias untar="tar -xzf"
alias unmount="umount" alias unmount="umount"
alias psk="pkill"
# git # git
alias gp="git stash && git pull && git stash pop" alias gp="git stash && git pull && git stash pop"
alias gf="git fetch" alias gf="git fetch"