Didn't learn to use awk or grep? This tool uses python regex syntax to parse stdin.
Clone:
git clone [email protected]:jarvainen/pyre.git
or just copy the code, it's one simple script.
Add to PATH or symlink to /bin
.
First parameter is regex, second parameter is output format:
echo 'Firstname Lastname' | pyre '(.*) (.*)' '2, 1'
Output format is string where numbers represent capture group.