You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

57 lines
1.5 KiB

name: Gen Docs
on:
workflow_dispatch:
workflow_call:
# push:
# branches:
# - main
# paths:
# - 'TermTk/**'
# - 'docs/**'
# - 'tests/**'
# - 'tutorial/**'
# release:
# types:
# - created # Trigger the workflow when a release is created
permissions:
contents: write
pull-requests: write
actions: read
pages: write
id-token: write
jobs:
gen-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.sha }}
- name: Gen Docs
run: |
echo "Generating Docs"
make doc
- name: clone pyTermTk-docs
env:
GITHUB_TOKEN: ${{ secrets.GH_PAT_TOKEN }}
run: |
git config --global user.name 'Eugenio Parodi - Action'
git config --global user.email 'ceccopierangioliegenio@googlemail.com'
git clone https://${GITHUB_TOKEN}@github.com/ceccopierangiolieugenio/pyTermTk-Docs.git
cd pyTermTk-Docs
git fetch --all
git checkout docs
cp -a \
../docs/source/_build/html/* \
../docs/source/_build/html/.buildinfo \
../docs/source/_build/html/.nojekyll \
.
git add --all
git commit -m "chore: updated docs - ($(date))"
git push --force origin docs
git checkout gh-pages
git reset --hard initial-commit
git merge docs -m "chore: merged docs - ($(date))"
git push --force origin gh-pages