Hello list,
I need some help with downloading all french pronunciation files (the
ogg files) off the
fr.wiktionary.org.
As a work around I have this:
grep -o audio=.*ogg frwiktionary-20081228-pages-articles.xml |sed 's/
audio=\([aA-zZ].*\)/curl\ -sO\ \"\http\:\/\/fr\.wiktionary\.org\/wiki\/
Fichier:\1\"/g' > filenames
which extracts all file_names from `frwiktionary-20081228-pages-
articles.xml` and then I added this:
http://fr.wiktionary.org/wiki/Fichier:file_names
as this as the base url. So a simple
curl -O "http://fr.wiktionary.org/wiki/Fichier:Fr-chaise.ogg"
should Dload the any file. It all looks fine and rosy up to here but
when I open the file with QTPlayer it doesn't play and the info window
gives me 0 bytes whereas:
ls Fichier\:Fr-chaise.ogg
-rw-r--r-- - 24K 11 Jan 09:53 Fichier:Fr-chaise.ogg
There is nothing wrong with my players; this shell script:
test -d /tmp/frp || /bin/mkdir -p /tmp/frp ; cd /tmp/frp ; for i in $
(curl -s
http://fr.wiktionary.org/wiki/${1} |grep --only-matching
"http.*ogg"\" |/usr/bin/sed 's/\".*$//') ; do curl -sO
$i;
done && open -g -a itunes /tmp/frp/Fr-${1}*.ogg
works for most entries (try chaise). So I Dload the file Fr-chaise.ogg
and play the files with no problem. Also:
ls /Volumes/neo/Users/pm/Music/iTunes/iTunes\ Music/Unknown\ Artist/
Unknown\ Album/une\ chaise.ogg
-rw-r--r--@ - 15K 11 Jan 10:00 …/Music/iTunes/iTunes Music/Unknown
Artist/Unknown Album/une chaise.ogg
Thanks,