Copy env's pybabel into base dir to fix string extraction
The jinja2 extracter needs to know about our custom HighlightExtension (used on pages such as get-involved/develop/applications), which is not in the env's python path. Copying pybabel into the base dir gives it access to our modules. This is only required for string extraction; other scripts use pybabel from the env directly. If the env's pybabel version is updated, this copy must also be updated.
This commit is contained in:
@ -1,7 +1,7 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
. ./translation.vars
|
. ./translation.vars
|
||||||
|
|
||||||
TZ=UTC env/bin/pybabel extract --msgid-bugs-address="http://trac.i2p2.de" \
|
TZ=UTC ./pybabel extract --msgid-bugs-address="http://trac.i2p2.de" \
|
||||||
--project=$PROJECT \
|
--project=$PROJECT \
|
||||||
--version=$VERSION \
|
--version=$VERSION \
|
||||||
-F $BABELCFG \
|
-F $BABELCFG \
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
[python: **.py]
|
[python: **.py]
|
||||||
[jinja2: **/pages/**.html]
|
[jinja2: **/pages/**.html]
|
||||||
|
extensions=jinja2.ext.autoescape,jinja2.ext.with_,i2p2www.extensions.HighlightExtension
|
||||||
[jinja2: **/blog/**.rst]
|
[jinja2: **/blog/**.rst]
|
||||||
extensions=jinja2.ext.autoescape,jinja2.ext.with_
|
extensions=jinja2.ext.autoescape,jinja2.ext.with_
|
||||||
|
10
pybabel
Executable file
10
pybabel
Executable file
@ -0,0 +1,10 @@
|
|||||||
|
#!env/bin/python
|
||||||
|
# EASY-INSTALL-ENTRY-SCRIPT: 'Babel==0.9.6','console_scripts','pybabel'
|
||||||
|
__requires__ = 'Babel==0.9.6'
|
||||||
|
import sys
|
||||||
|
from pkg_resources import load_entry_point
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
sys.exit(
|
||||||
|
load_entry_point('Babel==0.9.6', 'console_scripts', 'pybabel')()
|
||||||
|
)
|
Reference in New Issue
Block a user