2 ms·
In bash... $(grep -i 'pattern' file | awk '{print $5}' | sed 's/^/cmd/g') ? Or surround in backticks `command which outputs text you want to run as
by michaelcampbell 14y ago
In bash...
$(grep -i 'pattern' file | awk '{print $5}' | sed 's/^/cmd/g')
?
Or surround in backticks
`command which outputs text you want to run as a command`
I prefer $() as they nest better.
Or have I misunderstood your question?
- yogione 14y agoThat's it $() works. thanks.