Skip to content

generate-ale-docs

generate-ale-docs #248

name: generate-ale-docs
on:
workflow_dispatch:
schedule:
- cron: '0 06 * * *'
jobs:
build-ale-doc:
permissions: write-all
runs-on: ubuntu-24.04
steps:
- name: checkout
uses: actions/checkout@v4
- name: "clone mod-ale source"
run: |
git clone --single-branch https://github.com/azerothcore/mod-ale
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'
architecture: 'x64'
- name: Install Python dependencies
run: pip install jinja2 typedecorator markdown
- name: Compile documentation
run: |
cd mod-ale/src/LuaEngine/docs/
python -m ALEDoc
- name: "commit ale docs"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
rm -rf docs
cp -r mod-ale/src/LuaEngine/docs/build docs
touch docs/.nojekyll
rm -rf mod-ale
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add docs/
if git status -- ":!docs/date.js" | grep -q "Changes to be committed"
then
git commit -m "chore: ALE documentation πŸŽ‰"
git push
else
echo "No changes detected"
fi