Doc updates. #34
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: Update documentation | |
on: | |
push: | |
branches: | |
- 'main' | |
jobs: | |
generate-docs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out main branch | |
uses: actions/checkout@v3 | |
- name: Install Lua | |
uses: leafo/[email protected] | |
with: | |
luaVersion: "5.4" | |
- name: Install Luarocks package manager | |
uses: leafo/[email protected] | |
- name: Install LDoc (with dependencies) | |
run: | | |
luarocks install ldoc | |
- name: Generate HTML documentation using LDoc | |
run: | | |
ldoc -c .docs/.ldoc/config.ldoc . | |
- name: Commit any changes made inside the .docs folder | |
uses: EndBug/[email protected] | |
with: | |
add: '.docs' | |
remove: '.lua' | |
default_author: github_actions | |
author_name: Noble Robot | |
author_email: [email protected] | |
message: '(Documentation updates)' | |
push: true | |
- name: Remove .lua | |
uses: JesseTG/[email protected] | |
with: | |
path: .lua | |
- name: Remove .luarocks | |
uses: JesseTG/[email protected] | |
with: | |
path: .luarocks | |
- uses: numtide/clean-git-action@v1 | |
- name: GitHub Pages Overwriter | |
uses: rayluo/[email protected] | |
with: | |
source-directory: .docs | |
target-branch: gh_pages |