Importing languages the rough way.

Guess it's not intended to do but this is how I import languages into Drupal 6.

  1. wget the language files needed
  2. run the script below which creates *_full.po files.
    #!/usr/bin/env bash

    for FILE in *.tar.gz
    do
      DIR=`basename $FILE ".tar.gz"`
      OUT="../${DIR}_full.po"
      [ -f $OUT ] && rm $OUT && echo "File $OUT removed ... "
      [ -d $DIR ] && rm -r $DIR && echo "directory $DIR gemoved ..."
      [ ! -d $DIR ] && mkdir $DIR && echo "directory $DIR created ..."
      cd $DIR
      tar xzf ../$FILE
      find . -type f -name "*.txt" -exec rm {} \;
      rm $OUT
      find . -type f -exec cat {} >> $OUT \;
      cd -
    done
  3. Import the 'full' po files through the web interface
  4. Choose override existing string

Reacties

Nieuwe reactie inzenden

De inhoud van dit veld is privé en zal niet openbaar worden gemaakt.
  • Adressen van webpagina's en e-mailadressen worden automatisch naar links omgezet.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Regels en paragrafen worden automatisch gesplitst.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.

Meer informatie over formaatmogelijkheden

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
Image CAPTCHA
Enter the characters (without spaces) shown in the image.