Show More
@@ -27,6 +27,7 b' Output/Mercurial-*.exe' | |||||
27 | .DS_Store |
|
27 | .DS_Store | |
28 | tags |
|
28 | tags | |
29 | cscope.* |
|
29 | cscope.* | |
|
30 | i18n/hg.pot | |||
30 |
|
31 | |||
31 | syntax: regexp |
|
32 | syntax: regexp | |
32 | ^\.pc/ |
|
33 | ^\.pc/ |
@@ -13,6 +13,7 b' help:' | |||||
13 | @echo ' dist - run all tests and create a source tarball in dist/' |
|
13 | @echo ' dist - run all tests and create a source tarball in dist/' | |
14 | @echo ' clean - remove files created by other targets' |
|
14 | @echo ' clean - remove files created by other targets' | |
15 | @echo ' (except installed files or dist source tarball)' |
|
15 | @echo ' (except installed files or dist source tarball)' | |
|
16 | @echo ' update-pot - update i18n/hg.pot' | |||
16 | @echo |
|
17 | @echo | |
17 | @echo 'Example for a system-wide installation under /usr/local:' |
|
18 | @echo 'Example for a system-wide installation under /usr/local:' | |
18 | @echo ' make all && su -c "make install" && hg version' |
|
19 | @echo ' make all && su -c "make install" && hg version' | |
@@ -74,6 +75,14 b' tests:' | |||||
74 | test-%: |
|
75 | test-%: | |
75 | cd tests && $(PYTHON) run-tests.py $(TESTFLAGS) $@ |
|
76 | cd tests && $(PYTHON) run-tests.py $(TESTFLAGS) $@ | |
76 |
|
77 | |||
|
78 | update-pot: | |||
|
79 | mkdir -p i18n | |||
|
80 | pygettext -d doc -p i18n --docstrings \ | |||
|
81 | mercurial/commands.py hgext/*.py hgext/*/__init__.py | |||
|
82 | pygettext -d all -p i18n mercurial hgext doc | |||
|
83 | msgcat i18n/doc.pot i18n/all.pot > i18n/hg.pot | |||
|
84 | rm i18n/doc.pot i18n/all.pot | |||
77 |
|
85 | |||
78 | .PHONY: help all local build doc clean install install-bin install-doc \ |
|
86 | .PHONY: help all local build doc clean install install-bin install-doc \ | |
79 | install-home install-home-bin install-home-doc dist dist-notests tests |
|
87 | install-home install-home-bin install-home-doc dist dist-notests tests \ | |
|
88 | update-pot |
@@ -149,6 +149,12 b' try:' | |||||
149 | except ImportError: |
|
149 | except ImportError: | |
150 | pass |
|
150 | pass | |
151 |
|
151 | |||
|
152 | datafiles = [] | |||
|
153 | for root in ('templates', 'i18n'): | |||
|
154 | for dir, dirs, files in os.walk(root): | |||
|
155 | datafiles.append((os.path.join('mercurial', dir), | |||
|
156 | [os.path.join(dir, file_) for file_ in files])) | |||
|
157 | ||||
152 | setup(name='mercurial', |
|
158 | setup(name='mercurial', | |
153 | version=version, |
|
159 | version=version, | |
154 | author='Matt Mackall', |
|
160 | author='Matt Mackall', | |
@@ -159,9 +165,7 b" setup(name='mercurial'," | |||||
159 | scripts=scripts, |
|
165 | scripts=scripts, | |
160 | packages=packages, |
|
166 | packages=packages, | |
161 | ext_modules=ext_modules, |
|
167 | ext_modules=ext_modules, | |
162 | data_files=[(os.path.join('mercurial', root), |
|
168 | data_files=datafiles, | |
163 | [os.path.join(root, file_) for file_ in files]) |
|
|||
164 | for root, dirs, files in os.walk('templates')], |
|
|||
165 | cmdclass=cmdclass, |
|
169 | cmdclass=cmdclass, | |
166 | options=dict(py2exe=dict(packages=['hgext', 'email']), |
|
170 | options=dict(py2exe=dict(packages=['hgext', 'email']), | |
167 | bdist_mpkg=dict(zipdist=True, |
|
171 | bdist_mpkg=dict(zipdist=True, |
General Comments 0
You need to be logged in to leave comments.
Login now