File indexing completed on 2024-04-21 05:32:52

0001 #!/usr/bin/env bash
0002 
0003 # We fill in the en "translations" manually. We extract this to the KDE system as pot as normal, then populate the other json files
0004 
0005 
0006 # The name of catalog we create (without the.pot extension), sourced from the scripty scripts
0007 FILENAME="plasma-browser-extension"
0008 
0009 function export_pot_file # First parameter will be the path of the pot file we have to create, includes $FILENAME
0010 {
0011     potfile=$1
0012     python3 ./util/convertjsontopot.py $potfile
0013 }
0014 
0015 function import_po_files # First parameter will be a path that will contain several .po files with the format LANG.po
0016 {
0017     podir=$1
0018     for file in `ls $podir`
0019     do
0020         lang=${file%.po} #remove .po from end of file
0021         python3 ./util/convertpottojson.py $podir/$file $lang
0022     done
0023 }
0024