I'm a bit stuck into an issue on how to declare a grep from within a perl script. What I want to do is let my perl script to execute the following command:
cat config.ini | grep -v "^#" | grep -v "^$"
Normally this expression will clean up / filter all the entries who have # and $ at the beginning and print the variables configured.
However I don't know how to declare it. I have used next expression, but when i get to the point to introduce grep # or $ it fails
system("(cat config.ini| grep ........);
Any suggestion?