summaryrefslogtreecommitdiff
path: root/corpus
diff options
context:
space:
mode:
authorPatrick Simianer <p@simianer.de>2014-01-13 12:37:45 +0100
committerPatrick Simianer <p@simianer.de>2014-01-13 12:37:45 +0100
commit6ec8836c01223994816be6b7bdbb9abf136a1343 (patch)
tree3ded58a7f26854fdeb89451059618e7116b3b6ca /corpus
parent70b5d1ddbce169426f7cbdfcfe9186346bea3012 (diff)
parenta1cf0d10fe44ede32d29be37107884b734d459ae (diff)
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'corpus')
-rwxr-xr-xcorpus/tokenize-anything.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/corpus/tokenize-anything.sh b/corpus/tokenize-anything.sh
index c7adfa61..5b7933d8 100755
--- a/corpus/tokenize-anything.sh
+++ b/corpus/tokenize-anything.sh
@@ -5,15 +5,17 @@ SUPPORT=$ROOTDIR/support
if [[ $# == 1 && $1 == '-u' ]] ; then
NORMARGS="--batchline"
+ SEDFLAGS="-u"
else
NORMARGS=""
+ SEDFLAGS=""
fi
$SUPPORT/utf8-normalize.sh $NORMARGS |
$SUPPORT/quote-norm.pl |
$SUPPORT/tokenizer.pl |
- sed -e 's/ al - / al-/g' |
+ sed $SEDFLAGS -e 's/ al - / al-/g' |
$SUPPORT/fix-contract.pl |
- sed -e 's/^ //' | sed -e 's/ $//' |
+ sed $SEDFLAGS -e 's/^ //' | sed $SEDFLAGS -e 's/ $//' |
perl -e '$|++; while(<>){s/(\d+)(\.+)$/$1 ./; s/(\d+)(\.+) \|\|\|/$1 . |||/; print;}'