dotfiles/home/private_dot_config/zsh/functions/top-cpu-user

4 lines
87 B
Text
Raw Normal View History

2024-08-21 11:31:41 -05:00
#!/usr/bin/env zsh
top -b -n 1 -u "$1" | awk 'NR>7 { sum += $9; } END { print sum; }'