Skip to content

Instantly share code, notes, and snippets.

@theothermattm
Created July 12, 2019 12:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save theothermattm/47717107821aa220ad40b59720d2106f to your computer and use it in GitHub Desktop.
Save theothermattm/47717107821aa220ad40b59720d2106f to your computer and use it in GitHub Desktop.
Sed - remove matched pattern simple script
# this chains them to make the regex easier to follow
sed -n -e 's/^${FIRSTPATTERN}//p' test.txt | sed -n -e 's/${SECONDPATTERN}//p'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment