12 lines
237 B
Bash
12 lines
237 B
Bash
# Find process and filter.
|
|
# Usage: ps [PROCESS]
|
|
function ps() {
|
|
local process="${1}"
|
|
|
|
if [[ "${process}" = "" ]]; then
|
|
/usr/bin/ps aux
|
|
else
|
|
/usr/bin/ps aux | sed -n -e "1p" -e "/${process}/Ip" | sed -e "/sed -n -e 1p -e/d"
|
|
fi
|
|
}
|