From 92d17d5e205c08ca0bcf880d35db010db356f127 Mon Sep 17 00:00:00 2001 From: hophacker Date: Sun, 25 Oct 2020 18:08:56 +0800 Subject: [PATCH] add pp which prints process info closer to what you need, add ss which sources two active updated scripts --- zsh/aliases.zsh | 3 +++ zsh/functions.zsh | 4 +--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/zsh/aliases.zsh b/zsh/aliases.zsh index bcf409f..3f4fdaa 100644 --- a/zsh/aliases.zsh +++ b/zsh/aliases.zsh @@ -261,3 +261,6 @@ alias docker_purge='docker stop $(docker ps -qa);docker rm $(docker ps -qa)' alias yarn_sass="SASS_BINARY_SITE=https://npm.taobao.org/mirrors/node-sass/ yarn" alias vim="nvim" alias k="kubectl" + +## source files +alias ss="source ~/.yadr/zsh/functions.zsh; source ~/.yadr/zsh/aliases.zsh" diff --git a/zsh/functions.zsh b/zsh/functions.zsh index 33d0d86..61774d5 100644 --- a/zsh/functions.zsh +++ b/zsh/functions.zsh @@ -17,7 +17,7 @@ function contains() { echo "n" return 1 } - +pp() { ps aux | grep "$1\|USER" | grep -v "grep" } function getIP () { echo $(grep $1 ~/.ssh/config -A 1 | tail -1 | tr -s ' ' | cut -d ' ' -f 3) } @@ -433,8 +433,6 @@ function dc { function get_ip_of_ssh_hostname { ssh -G $1 | awk '/^hostname / { print $2 }' } -unalias gc -unalias gcm function gc { while true;do users=($GIT_USERS)