Change workflow to build versioned docs on gh-pages

This commit is contained in:
Jordan Irwin 2021-08-16 02:23:30 -07:00
parent 6b3220048b
commit 06e4408b91
2 changed files with 10 additions and 12 deletions

View file

@ -1,31 +1,29 @@
name: Build Reference
name: Build Reference
on: on:
push: push:
branches: tags:
- master - 'v[0-9]*'
jobs: jobs:
build: build:
name: Build name: Build Reference
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Lua - name: Setup Lua
uses: leafo/gh-actions-lua@v8 uses: leafo/gh-actions-lua@v8
with: with:
luaVersion: 5.4 luaVersion: 5.4
- name: Setup Lua Rocks - name: Setup Lua Rocks
uses: leafo/gh-actions-luarocks@v4 uses: leafo/gh-actions-luarocks@v4
- name: Setup LDoc dependencies - name: Setup dependencies
run: luarocks install --only-deps https://raw.githubusercontent.com/lunarmodules/LDoc/master/ldoc-scm-3.rockspec run: luarocks install --only-deps https://raw.githubusercontent.com/lunarmodules/LDoc/master/ldoc-scm-3.rockspec
- name: Setup LDoc - name: Setup LDoc
run: git clone --single-branch --branch=custom https://github.com/AntumDeluge/ldoc.git .ldoc/ldoc && chmod +x .ldoc/ldoc/ldoc.lua run: git clone --single-branch --branch=custom https://github.com/AntumDeluge/LDoc.git ldoc
- name: Generate docs - name: Checkout & Build Docs
run: chmod +x .ldoc/gendoc.sh && ./.ldoc/gendoc.sh run: git clone https://github.com/AntumMT/mod-cleaner.git cleaner && cd cleaner && chmod +x .ldoc/build_versioned_docs.sh && ./.ldoc/build_versioned_docs.sh
- name: Deploy - name: Deploy
uses: peaceiris/actions-gh-pages@v3 uses: peaceiris/actions-gh-pages@v3
with: with:
github_token: ${{ secrets.GITHUB_TOKEN }} github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/ publish_dir: cleaner/docs/

View file

@ -76,7 +76,7 @@ cleaner.unsafe
- [![ContentDB](https://content.minetest.net/packages/AntumDeluge/cleaner/shields/title/)][ContentDB] - [![ContentDB](https://content.minetest.net/packages/AntumDeluge/cleaner/shields/title/)][ContentDB]
- [Forum](https://forum.minetest.net/viewtopic.php?t=18381) - [Forum](https://forum.minetest.net/viewtopic.php?t=18381)
- [Git repo](https://github.com/AntumMT/mod-cleaner) - [Git repo](https://github.com/AntumMT/mod-cleaner)
- [Reference](https://antummt.github.io/mod-cleaner/reference) - [Reference](https://antummt.github.io/mod-cleaner/reference/latest/)
- [Changelog](changelog.txt) - [Changelog](changelog.txt)
- [TODO](TODO.txt) - [TODO](TODO.txt)