Mercurial > repo
view bin/hyphenate.fi @ 2016:16674c4f830c
<oerjan> addquote <Bike> if you say "java" three times to a dark mirror does steele come out and lecture you about operator overloading
author | HackBot |
---|---|
date | Wed, 06 Feb 2013 20:36:14 +0000 |
parents | 77ba48eeaa0e |
children |
line wrap: on
line source
#!/bin/sh exec perl -CS -Mutf8 -pwe 'my$vow=qr/[aeiouyäö]/i;my$con=qr/[b-df-hj-np-tv-xz]/i;1while s/($vow$con*)($con$vow)/$1-$2/g;1while s/a[eoyäö]|e[aoäö]|i[aoäö]|o[aeyäö]|u[aeyäö]|y[aeouä]|ä[aeouö]|ö[aeouä]/my@s=split"",$&;$s[0]."-".$s[1]/egi'