Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
d55d5c93
Commit
d55d5c93
authored
Apr 29, 2013
by
Steve Strassmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
addressed Don\'s comments on pull request
parent
3fd004e2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
10 deletions
+4
-10
i18n/generate.py
+2
-2
i18n/test/test_extract.py
+2
-8
No files found.
i18n/generate.py
View file @
d55d5c93
...
...
@@ -21,7 +21,7 @@ def merge(locale, target='django.po'):
"""
For the given locale, merge django-partial.po, messages.po, mako.po -> django.po
"""
LOG
.
info
(
'Merging locale=
%
s'
%
locale
)
LOG
.
info
(
'Merging locale=
{0}'
.
format
(
locale
)
)
locale_directory
=
messages_dir
(
locale
)
files_to_merge
=
(
'django-partial.po'
,
'messages.po'
,
'mako.po'
)
validate_files
(
locale_directory
,
files_to_merge
)
...
...
@@ -45,7 +45,7 @@ def validate_files(dir, files_to_merge):
for
path
in
files_to_merge
:
pathname
=
os
.
path
.
join
(
dir
,
path
)
if
not
os
.
path
.
exists
(
pathname
):
raise
Exception
(
"File not found:
%
s"
%
pathname
)
raise
Exception
(
"File not found:
{0}"
.
format
(
pathname
)
)
def
main
():
configuration
=
get_config
()
...
...
i18n/test/test_extract.py
View file @
d55d5c93
...
...
@@ -22,16 +22,10 @@ class TestExtract(TestCase):
self
.
start_time
=
datetime
.
now
()
-
timedelta
(
seconds
=
1
)
super
(
TestExtract
,
self
)
.
setUp
()
if
not
SETUP_HAS_RUN
:
self
.
run_main
()
# Run extraction script. Warning, this takes 1 minute or more
extract
.
main
()
SETUP_HAS_RUN
=
True
def
run_main
(
self
):
# Run extraction script. Warning, this takes 1 minute or more
print
"***********************"
print
"***********************"
print
"***********************"
extract
.
main
()
def
get_files
(
self
):
"""
This is a generator.
...
...
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