I am trying to get this output
15% abc
7% xyz
Running this command
ps axo pmem,args --sort -pmem,-rss,-vsz | grep -v grep |
grep -e abc-e xyz | awk {'print $1'}
How can I fit my grep -e arguments inside the output?
Right now, predictably, I am only getting
15%
7%
You can assume that my Python script is creating the command on the fly and that I can modify it any way I need to.
psoutput with app namegreps and just do the matching withinawk.