X Tutup
Skip to content

Commit 4854ecb

Browse files
committed
More translatable strings
Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
1 parent 2c841a8 commit 4854ecb

File tree

8 files changed

+167
-25
lines changed

8 files changed

+167
-25
lines changed

bpython/curtsiesfrontend/repl.py

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -485,10 +485,13 @@ def process_control_event(self, e):
485485
elif isinstance(e, bpythonevents.ReloadEvent):
486486
if self.watching_files:
487487
self.clear_modules_and_reevaluate()
488-
self.status_bar.message('Reloaded at ' + time.strftime('%H:%M:%S') + ' because ' + ' & '.join(e.files_modified) + ' modified')
488+
self.status_bar.message(
489+
_('Reloaded at %s because %s modified.') % (
490+
time.strftime('%X'),
491+
' & '.join(e.files_modified)))
489492

490493
else:
491-
raise ValueError("don't know how to handle this event type: %r" % e)
494+
raise ValueError("Don't know how to handle event type: %r" % e)
492495

493496
def process_key_event(self, e):
494497
# To find the curtsies name for a keypress, try python -m curtsies.events
@@ -739,22 +742,24 @@ def clear_modules_and_reevaluate(self):
739742
del sys.modules[modname]
740743
self.reevaluate(insert_into_history=True)
741744
self.cursor_offset, self.current_line = cursor, line
742-
self.status_bar.message('Reloaded at ' + time.strftime('%H:%M:%S') + ' by user')
745+
self.status_bar.message(_('Reloaded at %s by user.') % \
746+
(time.strftime('%X'), ))
743747

744748
def toggle_file_watch(self):
745749
if self.watcher:
746750
if self.watching_files:
747-
msg = "Auto-reloading deactivated"
751+
msg = _("Auto-reloading deactivated.")
748752
self.status_bar.message(msg)
749753
self.watcher.deactivate()
750754
self.watching_files = False
751755
else:
752-
msg = "Auto-reloading active, watching for file changes..."
756+
msg = _("Auto-reloading active, watching for file changes...")
753757
self.status_bar.message(msg)
754758
self.watching_files = True
755759
self.watcher.activate()
756760
else:
757-
self.status_bar.message('Autoreloading not available because watchdog not installed')
761+
self.status_bar.message(_('Auto-reloading not available because '
762+
'watchdog not installed.'))
758763

759764
## Handler Helpers
760765
def add_normal_character(self, char):

bpython/repl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -786,7 +786,7 @@ def do_pastebin_helper(self, s):
786786
if helper.returncode != 0:
787787
self.interact.notify(_('Upload failed: '
788788
'Helper program returned non-zero exit '
789-
'status %s.' % (helper.returncode, )))
789+
'status %d.' % (helper.returncode, )))
790790
return
791791

792792
if not paste_url:

bpython/translations/bpython.pot

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
#, fuzzy
77
msgid ""
88
msgstr ""
9-
"Project-Id-Version: bpython 0.13-493\n"
9+
"Project-Id-Version: bpython 0.13-494\n"
1010
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
11-
"POT-Creation-Date: 2015-02-02 00:30+0100\n"
11+
"POT-Creation-Date: 2015-02-02 17:34+0100\n"
1212
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
1313
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
1414
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -180,7 +180,7 @@ msgstr ""
180180

181181
#: bpython/repl.py:789
182182
#, python-format
183-
msgid "Upload failed: Helper program returned non-zero exit status %s."
183+
msgid "Upload failed: Helper program returned non-zero exit status %d."
184184
msgstr ""
185185

186186
#: bpython/repl.py:793
@@ -265,3 +265,25 @@ msgstr ""
265265
msgid "Executing PYTHONSTARTUP failed: %s"
266266
msgstr ""
267267

268+
#: bpython/curtsiesfrontend/repl.py:489
269+
#, python-format
270+
msgid "Reloaded at %s because %s modified."
271+
msgstr ""
272+
273+
#: bpython/curtsiesfrontend/repl.py:745
274+
#, python-format
275+
msgid "Reloaded at %s by user."
276+
msgstr ""
277+
278+
#: bpython/curtsiesfrontend/repl.py:751
279+
msgid "Auto-reloading deactivated."
280+
msgstr ""
281+
282+
#: bpython/curtsiesfrontend/repl.py:756
283+
msgid "Auto-reloading active, watching for file changes..."
284+
msgstr ""
285+
286+
#: bpython/curtsiesfrontend/repl.py:761
287+
msgid "Auto-reloading not available because watchdog not installed."
288+
msgstr ""
289+

bpython/translations/de/LC_MESSAGES/bpython.po

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: bpython mercurial\n"
99
"Report-Msgid-Bugs-To: http://github.com/bpython/bpython/issues\n"
10-
"POT-Creation-Date: 2015-02-02 00:30+0100\n"
10+
"POT-Creation-Date: 2015-02-02 17:34+0100\n"
1111
"PO-Revision-Date: 2015-02-02 00:31+0100\n"
1212
"Last-Translator: Sebastian Ramacher <sebastian+dev@ramacher.at>\n"
1313
"Language-Team: de <LL@li.org>\n"
@@ -181,8 +181,8 @@ msgstr ""
181181
"werden."
182182

183183
#: bpython/repl.py:789
184-
#, python-format
185-
msgid "Upload failed: Helper program returned non-zero exit status %s."
184+
#, fuzzy, python-format
185+
msgid "Upload failed: Helper program returned non-zero exit status %d."
186186
msgstr "Hochladen ist fehlgeschlagen: Hilfsprogramm beendete mit Status %s."
187187

188188
#: bpython/repl.py:793
@@ -272,3 +272,26 @@ msgstr "Drücke <%s> für Hilfe."
272272
#, python-format
273273
msgid "Executing PYTHONSTARTUP failed: %s"
274274
msgstr "Fehler beim Ausführen von PYTHONSTARTUP: %s"
275+
276+
#: bpython/curtsiesfrontend/repl.py:489
277+
#, python-format
278+
msgid "Reloaded at %s because %s modified."
279+
msgstr ""
280+
281+
#: bpython/curtsiesfrontend/repl.py:745
282+
#, python-format
283+
msgid "Reloaded at %s by user."
284+
msgstr ""
285+
286+
#: bpython/curtsiesfrontend/repl.py:751
287+
msgid "Auto-reloading deactivated."
288+
msgstr ""
289+
290+
#: bpython/curtsiesfrontend/repl.py:756
291+
msgid "Auto-reloading active, watching for file changes..."
292+
msgstr ""
293+
294+
#: bpython/curtsiesfrontend/repl.py:761
295+
msgid "Auto-reloading not available because watchdog not installed."
296+
msgstr ""
297+

bpython/translations/es_ES/LC_MESSAGES/bpython.po

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: bpython 0.9.7\n"
99
"Report-Msgid-Bugs-To: http://github.com/bpython/bpython/issues\n"
10-
"POT-Creation-Date: 2015-02-02 00:30+0100\n"
11-
"PO-Revision-Date: 2015-02-02 00:31+0100\n"
10+
"POT-Creation-Date: 2015-02-02 17:34+0100\n"
11+
"PO-Revision-Date: 2015-02-02 00:34+0100\n"
1212
"Last-Translator: Sebastian Ramacher <sebastian+dev@ramacher.at>\n"
1313
"Language-Team: bpython developers\n"
1414
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
@@ -180,7 +180,7 @@ msgstr ""
180180

181181
#: bpython/repl.py:789
182182
#, python-format
183-
msgid "Upload failed: Helper program returned non-zero exit status %s."
183+
msgid "Upload failed: Helper program returned non-zero exit status %d."
184184
msgstr ""
185185

186186
#: bpython/repl.py:793
@@ -266,3 +266,26 @@ msgstr ""
266266
#, python-format
267267
msgid "Executing PYTHONSTARTUP failed: %s"
268268
msgstr ""
269+
270+
#: bpython/curtsiesfrontend/repl.py:489
271+
#, python-format
272+
msgid "Reloaded at %s because %s modified."
273+
msgstr ""
274+
275+
#: bpython/curtsiesfrontend/repl.py:745
276+
#, python-format
277+
msgid "Reloaded at %s by user."
278+
msgstr ""
279+
280+
#: bpython/curtsiesfrontend/repl.py:751
281+
msgid "Auto-reloading deactivated."
282+
msgstr ""
283+
284+
#: bpython/curtsiesfrontend/repl.py:756
285+
msgid "Auto-reloading active, watching for file changes..."
286+
msgstr ""
287+
288+
#: bpython/curtsiesfrontend/repl.py:761
289+
msgid "Auto-reloading not available because watchdog not installed."
290+
msgstr ""
291+

bpython/translations/fr_FR/LC_MESSAGES/bpython.po

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ msgid ""
66
msgstr ""
77
"Project-Id-Version: bpython 0.13-442\n"
88
"Report-Msgid-Bugs-To: http://github.com/bpython/bpython/issues\n"
9-
"POT-Creation-Date: 2015-02-02 00:30+0100\n"
9+
"POT-Creation-Date: 2015-02-02 17:34+0100\n"
1010
"PO-Revision-Date: 2015-02-02 00:31+0100\n"
1111
"Last-Translator: Sebastian Ramacher <sebastian+dev@ramacher.at>\n"
1212
"Language-Team: bpython developers\n"
@@ -183,8 +183,8 @@ msgid "Upload failed: Helper program could not be run."
183183
msgstr "Echec de l'upload: impossible de lancer le programme externe."
184184

185185
#: bpython/repl.py:789
186-
#, python-format
187-
msgid "Upload failed: Helper program returned non-zero exit status %s."
186+
#, fuzzy, python-format
187+
msgid "Upload failed: Helper program returned non-zero exit status %d."
188188
msgstr ""
189189
"Echec de l'upload: le programme externe a renvoyé un statut de sortie "
190190
"différent de zéro %s."
@@ -276,3 +276,26 @@ msgstr "Appuyer sur <%s> pour de l'aide."
276276
#, python-format
277277
msgid "Executing PYTHONSTARTUP failed: %s"
278278
msgstr "L'exécution de PYTHONSTARTUP a échoué: %s"
279+
280+
#: bpython/curtsiesfrontend/repl.py:489
281+
#, python-format
282+
msgid "Reloaded at %s because %s modified."
283+
msgstr ""
284+
285+
#: bpython/curtsiesfrontend/repl.py:745
286+
#, python-format
287+
msgid "Reloaded at %s by user."
288+
msgstr ""
289+
290+
#: bpython/curtsiesfrontend/repl.py:751
291+
msgid "Auto-reloading deactivated."
292+
msgstr ""
293+
294+
#: bpython/curtsiesfrontend/repl.py:756
295+
msgid "Auto-reloading active, watching for file changes..."
296+
msgstr ""
297+
298+
#: bpython/curtsiesfrontend/repl.py:761
299+
msgid "Auto-reloading not available because watchdog not installed."
300+
msgstr ""
301+

bpython/translations/it_IT/LC_MESSAGES/bpython.po

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: bpython 0.9.7\n"
99
"Report-Msgid-Bugs-To: http://github.com/bpython/bpython/issues\n"
10-
"POT-Creation-Date: 2015-02-02 00:30+0100\n"
11-
"PO-Revision-Date: 2015-02-02 00:31+0100\n"
10+
"POT-Creation-Date: 2015-02-02 17:34+0100\n"
11+
"PO-Revision-Date: 2015-02-02 00:34+0100\n"
1212
"Last-Translator: Sebastian Ramacher <sebastian+dev@ramacher.at>\n"
1313
"Language-Team: Michele Orrù\n"
1414
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
@@ -180,7 +180,7 @@ msgstr ""
180180

181181
#: bpython/repl.py:789
182182
#, python-format
183-
msgid "Upload failed: Helper program returned non-zero exit status %s."
183+
msgid "Upload failed: Helper program returned non-zero exit status %d."
184184
msgstr ""
185185

186186
#: bpython/repl.py:793
@@ -264,3 +264,26 @@ msgstr ""
264264
#, python-format
265265
msgid "Executing PYTHONSTARTUP failed: %s"
266266
msgstr ""
267+
268+
#: bpython/curtsiesfrontend/repl.py:489
269+
#, python-format
270+
msgid "Reloaded at %s because %s modified."
271+
msgstr ""
272+
273+
#: bpython/curtsiesfrontend/repl.py:745
274+
#, python-format
275+
msgid "Reloaded at %s by user."
276+
msgstr ""
277+
278+
#: bpython/curtsiesfrontend/repl.py:751
279+
msgid "Auto-reloading deactivated."
280+
msgstr ""
281+
282+
#: bpython/curtsiesfrontend/repl.py:756
283+
msgid "Auto-reloading active, watching for file changes..."
284+
msgstr ""
285+
286+
#: bpython/curtsiesfrontend/repl.py:761
287+
msgid "Auto-reloading not available because watchdog not installed."
288+
msgstr ""
289+

bpython/translations/nl_NL/LC_MESSAGES/bpython.po

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: bpython 0.9.7.1\n"
99
"Report-Msgid-Bugs-To: http://github.com/bpython/bpython/issues\n"
10-
"POT-Creation-Date: 2015-02-02 00:30+0100\n"
11-
"PO-Revision-Date: 2015-02-02 00:31+0100\n"
10+
"POT-Creation-Date: 2015-02-02 17:34+0100\n"
11+
"PO-Revision-Date: 2015-02-02 00:34+0100\n"
1212
"Last-Translator: Sebastian Ramacher <sebastian+dev@ramacher.at>\n"
1313
"Language-Team: bpython developers\n"
1414
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
@@ -180,7 +180,7 @@ msgstr ""
180180

181181
#: bpython/repl.py:789
182182
#, python-format
183-
msgid "Upload failed: Helper program returned non-zero exit status %s."
183+
msgid "Upload failed: Helper program returned non-zero exit status %d."
184184
msgstr ""
185185

186186
#: bpython/repl.py:793
@@ -264,3 +264,26 @@ msgstr ""
264264
#, python-format
265265
msgid "Executing PYTHONSTARTUP failed: %s"
266266
msgstr ""
267+
268+
#: bpython/curtsiesfrontend/repl.py:489
269+
#, python-format
270+
msgid "Reloaded at %s because %s modified."
271+
msgstr ""
272+
273+
#: bpython/curtsiesfrontend/repl.py:745
274+
#, python-format
275+
msgid "Reloaded at %s by user."
276+
msgstr ""
277+
278+
#: bpython/curtsiesfrontend/repl.py:751
279+
msgid "Auto-reloading deactivated."
280+
msgstr ""
281+
282+
#: bpython/curtsiesfrontend/repl.py:756
283+
msgid "Auto-reloading active, watching for file changes..."
284+
msgstr ""
285+
286+
#: bpython/curtsiesfrontend/repl.py:761
287+
msgid "Auto-reloading not available because watchdog not installed."
288+
msgstr ""
289+

0 commit comments

Comments
 (0)
X Tutup