Created
July 2, 2020 19:16
-
-
Save RichardBronosky/e570319f6f70c676208efb1abbaabcc6 to your computer and use it in GitHub Desktop.
grepped top (top, limited to commands filtered via regex arg)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# only tested on macOS | |
gtop(){ pattern="${1:-WindowServer}"; top $(ps -haxl | awk '/'"$pattern"'/{print "-pid " $2}'); } | |
gtop Chrome |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment