Skip to content
Snippets Groups Projects

Skip i18n-specific things if website is not i18n

Merged Jérôme Charaoui requested to merge skip-i18n into main
3 unresolved threads
1 file
+ 15
9
Compare changes
  • Side-by-side
  • Inline
+ 15
9
@@ -37,18 +37,24 @@ pages:
stage: build
script:
- *apt-template
- DEBIAN_FRONTEND=noninteractive apt-get install gettext python3-babel python3-pip git python3-inifile python3-dev python3-setuptools python3-openssl python3-cryptography python3-venv i18nspector apt-utils ca-certificates -y
- DEBIAN_FRONTEND=noninteractive apt-get install python3-pip git python3-inifile python3-dev python3-setuptools python3-openssl python3-cryptography python3-venv apt-utils ca-certificates -y
- python3 -m venv venv
- source venv/bin/activate
- pip3 install lektor
- echo 'checking out translations'
- rm -rf i18n
- git clone --branch $TRANSLATION_BRANCH --depth=1 https://git.torproject.org/translation.git i18n
- echo 'reinstall lektor plugins'
- lektor project-info --output-path
- lektor plugins reinstall
- echo 'building lektor 3 more times to get translations in place'
- lektor build --output-path public && lektor build --output-path public && lektor build --output-path public
- >
if [ -n "${TRANSLATION_BRANCH}" ]; then
DEBIAN_FRONTEND=noninteractive apt-get install gettext python3-babel i18nspector
echo 'checking out translations'
rm -rf i18n
git clone --branch "${TRANSLATION_BRANCH}" --depth=1 https://git.torproject.org/translation.git i18n
echo 'reinstall lektor plugins'
lektor project-info --output-path
lektor plugins reinstall
echo 'building lektor 3 more times to get translations in place'
lektor build --output-path public && lektor build --output-path public && lektor build --output-path public
else
lektor build --output-path public
fi
artifacts:
paths:
- public
Loading