This repository has been archived by the owner on Feb 22, 2024. It is now read-only.
New Crowdin updates #4371
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Staging translated Qiskit Runtime docs | |
on: | |
pull_request: | |
branches: [ main ] | |
label: | |
types: [ gh-pages-runtime ] | |
jobs: | |
build_docs: | |
runs-on: ubuntu-latest | |
if: contains( github.event.pull_request.labels.*.name, 'gh-pages-runtime' ) | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
persist-credentials: false | |
fetch-depth: 0 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.9' | |
- name: Install Qiskit IBM Runtime dependencies | |
run: | | |
cd qiskit-ibm-runtime | |
python -m pip install --upgrade pip | |
pip install -U virtualenv setuptools wheel tox | |
pip install -e . | |
sudo apt-get install -y graphviz pandoc | |
pip install -U -r requirements-dev.txt -r requirements.txt sphinx-intl nbsphinx qiskit_sphinx_theme | |
- name: Build translated Qiskit IBM Runtime Docs | |
env: | |
TRANSLATION_LANG: ${{ matrix.language }} | |
run: | | |
cd qiskit-ibm-runtime | |
../tools/staging_runtime_translated_documentation.sh | |
- name: Compress artifact | |
run: | | |
mkdir artifacts | |
cd qiskit-ibm-runtime && tar -zcvf runtime_translated_docs_${{matrix.language}}.tar.gz build | |
mv runtime_translated_docs_${{matrix.language}}.tar.gz ../artifacts/. | |
- name: Upload artifact | |
uses: actions/upload-artifact@main | |
with: | |
name: qiskit-translated-docs | |
path: artifacts | |
strategy: | |
matrix: | |
language: | |
- bn_BN | |
# - de_DE | |
- es_UN | |
- fr_FR | |
- hi_IN | |
- ja_JP | |
- ko_KR | |
# - mr_IN | |
# - pl_PL | |
- pt_UN | |
# - ru_RU | |
- ta_IN | |
# - th_TH | |
- tr_TR | |
- zh_CN | |
- zh_TW | |
deploy_docs: | |
runs-on: ubuntu-latest | |
needs: build_docs | |
steps: | |
- uses: actions/checkout@main | |
- name: Download artifact | |
uses: actions/download-artifact@v2 | |
with: | |
name: qiskit-translated-docs | |
- name: Decompress artifact | |
run: | | |
for f in *.tar.gz; do tar -xvf "$f"; done | |
- name: Push directory to another repository | |
uses: cpina/github-action-push-to-another-repository@main | |
env: | |
API_TOKEN_GITHUB: ${{ secrets.STAGING_REPO }} | |
with: | |
source-directory: 'build' | |
destination-github-username: 'qiskit-community' | |
destination-repository-name: 'qiskit-translations-staging' | |
target-directory: 'runtime' | |
user-name: SooluThomas | |
user-email: [email protected] | |
target-branch: main | |
commit-message: Qiskit Autodeploy ORIGIN_COMMIT from $GITHUB_REF |