#!/bin/sh set -x if [ "$1" = "" ]; then echo usage $0 version [ tag ] exit 1 fi FOS=/usr/local/bin/fossil VER=$1 TAG=${2:-v$1} mkdir libreoffice-grammalecte-$VER pushd libreoffice-grammalecte-$VER $FOS clone -u http://code.grammalecte.net grammalecte.fossil $FOS open grammalecte.fossil $FOS checkout $TAG pushd gc_lang/fr/dictionnaire/lexique/corpus_data $FOS uv export stats_frwiki.txt stats_frwiki.txt $FOS uv export stats_frwikisource.txt stats_frwikisource.txt $FOS uv export stats_google_ngram_1.txt stats_google_ngram_1.txt $FOS uv export stats_litterature.txt stats_litterature.txt popd $FOS close rm grammalecte.fossil popd tar cJf libreoffice-grammalecte-$VER.tar.xz libreoffice-grammalecte-$VER rm -r libreoffice-grammalecte-$VER