diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f023ee932b1e8167bc682990286bf45c572ec907..51b9c86fb4bc40cb979edd2f0601450534a41d41 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -13,6 +13,7 @@ deploy-gtf-fr-documentation-dev : # - pip install sphinx-markdown-parser # - pip install myst-parser # - pip install pymdown-extensions + - pip install sphinxcontrib-phpdomain - sphinx-build -b html source build - aws s3 cp build/ s3://$S3_BUCKET_NAME_DEV_fr/ --recursive tags: diff --git a/README.md b/README.md index 29fa1f511ca076e1362527349a837e35d9f97539..b7a66763fe29b31961ba49f6d42362d5efce514d 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,7 @@ pip install sphinx_rtd_theme==0.5.2 pip install sphinx-markdown-parser pip install myst-parser pip install pymdown-extensions +pip install sphinxcontrib-phpdomain sphinx-build -b html source build ``` diff --git a/source/conf.py b/source/conf.py index b92a9230e04a6c7568bad6b90618176866714641..7aca07e83907017a20b3d4c90441f3bade0b0a08 100644 --- a/source/conf.py +++ b/source/conf.py @@ -3,6 +3,8 @@ import os from sphinx_markdown_parser.parser import MarkdownParser from datetime import datetime #from recommonmark.transform import AutoStructify +from sphinx.highlighting import lexers +from pygments.lexers.web import PhpLexer source_parsers = { '.md': 'CommonMarkParser', @@ -139,3 +141,8 @@ html_theme_options = { 'includehidden': True, 'titles_only': False } + + +lexers['php'] = PhpLexer(startinline=True, linenos=1) +lexers['php-annotations'] = PhpLexer(startinline=True, linenos=1) +primary_domain = 'php' \ No newline at end of file