Skip to content

Commit

Permalink
Deploy docs to GitHub Pages (#311)
Browse files Browse the repository at this point in the history
* Deploy docs to GitHub Pages

* Fix conf.py copyrighht date

* gettext removed

---------

Co-authored-by: Steve Wood <40241007+woodsp-ibm@users.noreply.github.com>
  • Loading branch information
arnaucasau and woodsp-ibm committed Jan 24, 2024
1 parent 98ac87a commit 7108f6a
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 167 deletions.
41 changes: 8 additions & 33 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,45 +41,20 @@ jobs:
pip install jupyter qiskit[visualization]
sudo apt-get install -y pandoc graphviz
shell: bash
- name: Build and publish
- name: Build docs
env:
encrypted_rclone_key: ${{ secrets.encrypted_rclone_key }}
encrypted_rclone_iv: ${{ secrets.encrypted_rclone_iv }}
QISKIT_PARALLEL: False
QISKIT_DOCS_BUILD_TUTORIALS: 'always'
run: |
echo "earliest_version: 0.1.0" >> releasenotes/config.yaml
tools/ignore_untagged_notes.sh
make html
tools/deploy_documentation.sh
shell: bash
deploy-translatable-strings:
if: ${{ startsWith(github.ref, 'refs/heads/stable') && contains('["t-imamichi","mtreinish","stefan-woerner","woodsp-ibm"]', github.actor) }}
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.8]
steps:
- uses: actions/checkout@v3
- name: Bypass Jekyll Processing # Necessary for setting the correct css path
run: touch docs/_build/html/.nojekyll
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install jupyter qiskit[visualization] torchvision tox
sudo apt-get install -y pandoc graphviz
shell: bash
- name: Build and publish
env:
encrypted_deploy_po_branch_key: ${{ secrets.encrypted_deploy_po_branch_key }}
encrypted_deploy_po_branch_iv: ${{ secrets.encrypted_deploy_po_branch_iv }}
QISKIT_PARALLEL: False
QISKIT_DOCS_BUILD_TUTORIALS: 'always'
run: |
echo "earliest_version: 0.1.0" >> releasenotes/config.yaml
tools/ignore_untagged_notes.sh
tools/deploy_translatable_strings.sh
shell: bash
folder: docs/_build/html/
clean-exclude: |
locale/*
6 changes: 2 additions & 4 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This code is part of a Qiskit project.
#
# (C) Copyright IBM 2021, 2023.
# (C) Copyright IBM 2021, 2024.
#
# This code is licensed under the Apache License, Version 2.0. You may
# obtain a copy of this license in the LICENSE.txt file in the root directory
Expand Down Expand Up @@ -93,7 +93,7 @@
]
templates_path = ["_templates"]

docs_url_prefix = "ecosystem/finance"
docs_url_prefix = "qiskit-finance"

nbsphinx_timeout = 360
nbsphinx_execute = os.getenv("QISKIT_DOCS_BUILD_TUTORIALS", "never")
Expand Down Expand Up @@ -144,8 +144,6 @@
("es_UN", "Spanish"),
]
language = "en"
locale_dirs = ["locale/"]
gettext_compact = False # optional.

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
Expand Down
29 changes: 0 additions & 29 deletions tools/deploy_documentation.sh

This file was deleted.

90 changes: 0 additions & 90 deletions tools/deploy_translatable_strings.sh

This file was deleted.

Binary file removed tools/github_poBranch_update_key.enc
Binary file not shown.
Binary file removed tools/rclone.conf.enc
Binary file not shown.
11 changes: 0 additions & 11 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,6 @@ basepython = python3
commands =
sphinx-build -j auto -W -T --keep-going -b html {posargs} docs/ docs/_build/html

[testenv:gettext]
envdir = .tox/docs
deps =
-r{toxinidir}/requirements.txt
-r{toxinidir}/requirements-dev.txt
sphinx-intl
jupyter
commands =
sphinx-build -W -T --keep-going -b gettext docs/ docs/_build/gettext {posargs}
sphinx-intl -c docs/conf.py update -p docs/_build/gettext -l en -d docs/locale

[testenv:docs-clean]
skip_install = true
deps =
Expand Down

0 comments on commit 7108f6a

Please sign in to comment.