Test
This commit is contained in:
21
.github/workflows/docs.yml
vendored
21
.github/workflows/docs.yml
vendored
@@ -13,19 +13,34 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- 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: Install LDoc
|
- name: Install LDoc
|
||||||
run: luarocks install ldoc
|
run: luarocks install ldoc
|
||||||
|
|
||||||
|
- name: Create docs directory
|
||||||
|
run: mkdir -p docs
|
||||||
|
|
||||||
- name: Build docs
|
- name: Build docs
|
||||||
run: make doc-site
|
run: |
|
||||||
|
ldoc .
|
||||||
|
ls -la docs || echo "Docs directory is empty"
|
||||||
|
if [ ! -d "docs" ] || [ -z "$(ls -A docs)" ]; then
|
||||||
|
echo "Documentation generation failed or produced no files"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
- name: Deploy
|
- name: Deploy
|
||||||
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
|
if: success() && github.event_name == 'push' && github.ref == 'refs/heads/main'
|
||||||
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: ./docs
|
||||||
|
force_orphan: true
|
||||||
Reference in New Issue
Block a user