Doc #5
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
# Based on https://gist.github.com/domenic/ec8b0fc8ab45f39403dd | |
name: Build Docs | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
name: Build docs | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup Lua | |
uses: leafo/gh-actions-lua@v8 | |
with: | |
luaVersion: 5.1 | |
- name: Setup Lua Rocks | |
run: sudo apt-get install -y luarocks | |
- name: Install LDoc | |
run: sudo luarocks install ldoc | |
- name: Build docs | |
run: | | |
mkdir -p doc | |
ldoc . --ext readme.md | |
mv ./doc/*.txt ./doc/neominimap.txt | |
- name: Deploy | |
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.PAT_TOKEN }} | |
publish_dir: ./doc |