Last active
November 24, 2015 17:34
-
-
Save vyuh/825a6f4c691965674fbc to your computer and use it in GitHub Desktop.
Filter english text files to one sentence per line.
This file contains 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
perl -M'Lingua::EN::Sentence qw/get_sentences/' -00 -lne 'tr/\r\n \t/ /s;print join "\n", @{get_sentences $_};' |
This file contains 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
#!/usr/bin/perl -M'Lingua::EN::Sentence qw/get_sentences/' -00 -ln | |
tr/\r\n \t/ /s; | |
print join "\n", @{get_sentences $_}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment