Skip to content

Documentation Generation #32

Documentation Generation

Documentation Generation #32

Workflow file for this run

on:
release:
types: [published]
workflow_dispatch:
inputs:
manual_tag:
description: 'release tag'
required: true
default: 'undefined'
type: string
name: Documentation Generation
jobs:
lua:
name: Lua Documentation
runs-on: ubuntu-latest
steps:
- name: Install alsa and udev
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: Swatinem/[email protected]
- run: cargo install --git https://github.com/lenscas/tealr_doc_gen
- run: mkdir -p ./assets/scripts/doc/
- run: cp tealr_doc_gen_config.json ./assets/scripts/doc/tealr_doc_gen_config.json
- run: sed -i "s/<page_root>/bevy_mod_scripting_lua\/${{github.event.release.tag_name || inputs.manual_tag}}\//" ./assets/scripts/doc/tealr_doc_gen_config.json
- uses: actions-rs/cargo@v1
with:
command: run
args: --features=lua54,lua_script_api lua
- run: cat ./assets/scripts/doc/tealr_doc_gen_config.json
- name: Push to pages
uses: cpina/github-action-push-to-another-repository@main
env:
SSH_DEPLOY_KEY: ${{ secrets.LUA_DOCUMENTATION_SSH_KEY }}
with:
source-directory: './assets/scripts/doc/BevyAPI/bevy_mod_scripting_lua/${{ github.event.release.tag_name || inputs.manual_tag }}'
destination-github-username: 'makspll'
destination-repository-name: 'bevy_mod_scripting_lua'
user-email: [email protected]
target-branch: main
target-directory: ${{ github.event.release.tag_name || inputs.manual_tag }}
- name: Pushes to pages as latest
if: ${{ github.event.release.tag_name }} == ''
uses: cpina/github-action-push-to-another-repository@main
env:
SSH_DEPLOY_KEY: ${{ secrets.LUA_DOCUMENTATION_SSH_KEY }}
with:
source-directory: './assets/scripts/doc/BevyAPI/bevy_mod_scripting_lua/${{ github.event.release.tag_name || inputs.manual_tag }}'
destination-github-username: 'makspll'
destination-repository-name: 'bevy_mod_scripting_lua'
user-email: [email protected]
target-branch: main
target-directory: latest