Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
16c43396
Kaydet (Commit)
16c43396
authored
May 19, 2014
tarafından
Claude Paroz
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
[1.7.x] Re-added JS catalog in manage_translations script
Backport of
d20aa78c
from master.
üst
1e78d132
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
manage_translations.py
scripts/manage_translations.py
+6
-4
No files found.
scripts/manage_translations.py
Dosyayı görüntüle @
16c43396
...
...
@@ -72,10 +72,10 @@ def _check_diff(cat_name, base_path):
"""
po_path
=
'
%(path)
s/en/LC_MESSAGES/django
%(ext)
s.po'
%
{
'path'
:
base_path
,
'ext'
:
'js'
if
cat_name
.
endswith
(
'-js'
)
else
''
}
p
=
Popen
(
"git diff -U0
%
s | egrep
-v '^@@|^[-+]#|^..POT-Creation
' | wc -l"
%
po_path
,
p
=
Popen
(
"git diff -U0
%
s | egrep
'^[-+]msgid
' | wc -l"
%
po_path
,
stdout
=
PIPE
,
stderr
=
PIPE
,
shell
=
True
)
output
,
errors
=
p
.
communicate
()
num_changes
=
int
(
output
.
strip
())
-
4
num_changes
=
int
(
output
.
strip
())
print
(
"
%
d changed/added messages in '
%
s' catalog."
%
(
num_changes
,
cat_name
))
...
...
@@ -91,9 +91,11 @@ def update_catalogs(resources=None, languages=None):
os
.
chdir
(
os
.
path
.
join
(
os
.
getcwd
(),
'django'
))
print
(
"Updating en catalogs for Django and contrib apps..."
)
call_command
(
'makemessages'
,
locale
=
[
'en'
])
_check_diff
(
'core'
,
os
.
path
.
join
(
os
.
getcwd
(),
'conf'
,
'locale'
))
print
(
"Updating en JS catalogs for Django and contrib apps..."
)
call_command
(
'makemessages'
,
locale
=
[
'en'
],
domain
=
'djangojs'
)
# Stats for contrib catalogs
# Output changed stats
_check_diff
(
'core'
,
os
.
path
.
join
(
os
.
getcwd
(),
'conf'
,
'locale'
))
for
name
,
dir_
in
contrib_dirs
:
_check_diff
(
name
,
dir_
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment