Last active
November 14, 2017 09:31
-
-
Save verajosemanuel/a352f2795428dbaac672d4727ecc4fe0 to your computer and use it in GitHub Desktop.
#sed insert newline between negative + positive pattern #bash #regex
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sed -r 's/([^.] )(WORD\. )/\1\n\2/g' | |
# sample | |
NOTNEEDED. WORD. 8 de 2007/04/12 Definitiva | |
1ª Conferencia mundial en londres WORD. 3901 de 2009/10/01 UTC | |
# output | |
NOTNEEDED. WORD. 8 de 2007/04/12 Definitiva | |
1ª Conferencia mundial en londres | |
WORD. 3901 de 2009/10/01 UTC |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment