Browse Source

Find files to translate automatically

3.2.x
Johann Bauer 7 years ago
parent
commit
eab5bcf62f
  1. 1
      .gitignore
  2. 1
      MANIFEST.in
  3. 55
      app.fil
  4. 11
      contrib/make_locale

1
.gitignore

@ -16,6 +16,7 @@ env/
.tox/
.buildozer/
bin/
/app.fil
# tox files
.cache/

1
MANIFEST.in

@ -11,7 +11,6 @@ recursive-include gui *.py
recursive-include plugins *.py
recursive-include packages *.py
recursive-include packages cacert.pem
include app.fil
include icons.qrc
recursive-include icons *
recursive-include scripts *

55
app.fil

@ -1,55 +0,0 @@
gui/qt/address_dialog.py
gui/qt/address_list.py
gui/qt/contact_list.py
gui/qt/exception_window.py
gui/qt/fee_slider.py
gui/qt/history_list.py
gui/qt/__init__.py
gui/qt/installwizard.py
gui/qt/invoice_list.py
gui/qt/main_window.py
gui/qt/network_dialog.py
gui/qt/password_dialog.py
gui/qt/qrcodewidget.py
gui/qt/qrtextedit.py
gui/qt/qrwindow.py
gui/qt/request_list.py
gui/qt/seed_dialog.py
gui/qt/transaction_dialog.py
gui/qt/util.py
gui/qt/utxo_list.py
lib/plot.py
plugins/audio_modem/__init__.py
plugins/audio_modem/qt.py
plugins/cosigner_pool/__init__.py
plugins/cosigner_pool/qt.py
plugins/digitalbitbox/digitalbitbox.py
plugins/digitalbitbox/__init__.py
plugins/digitalbitbox/qt.py
plugins/email_requests/__init__.py
plugins/email_requests/qt.py
plugins/greenaddress_instant/__init__.py
plugins/greenaddress_instant/qt.py
plugins/hw_wallet/plugin.py
plugins/hw_wallet/qt.py
plugins/keepkey/clientbase.py
plugins/keepkey/__init__.py
plugins/keepkey/plugin.py
plugins/keepkey/qt_generic.py
plugins/labels/__init__.py
plugins/labels/labels.py
plugins/labels/qt.py
plugins/ledger/auth2fa.py
plugins/ledger/__init__.py
plugins/ledger/ledger.py
plugins/ledger/qt.py
plugins/trezor/clientbase.py
plugins/trezor/__init__.py
plugins/trezor/qt_generic.py
plugins/trezor/trezor.py
plugins/trustedcoin/cmdline.py
plugins/trustedcoin/__init__.py
plugins/trustedcoin/qt.py
plugins/trustedcoin/trustedcoin.py
plugins/virtualkeyboard/__init__.py
plugins/virtualkeyboard/qt.py

11
contrib/make_locale

@ -1,5 +1,6 @@
#!/usr/bin/env python3
import os
import subprocess
import io
import zipfile
import requests
@ -7,6 +8,16 @@ import requests
os.chdir(os.path.dirname(os.path.realpath(__file__)))
os.chdir('..')
code_directories = 'lib gui plugins'
cmd = "grep 'from electrum.i18n import _' {} -rl".format(code_directories)
files = subprocess.check_output(cmd, shell=True)
with open("app.fil", "wb") as f:
f.write(files)
print("Found {} files to translate".format(len(files.splitlines())))
# Generate fresh translation template
if not os.path.exists('lib/locale'):
os.mkdir('lib/locale')

Loading…
Cancel
Save