Search & replace with find & ed

Image via Wikipedia function sr() { declare pattern replacement name usage declare -i pvar=0 rvar=0 tvar=0 usage=\’usage: sr [-t ]…

Continue Reading →

Display the output of a command from the first line until the first instance of a regular expression.

Image via Wikipedia | perl -n -e \’print \”$_\” if 1 … /<regex>/;# This command line will display the output…

Continue Reading →