actions: run lua-language-check and generate and upload docs

This commit is contained in:
Iampete1 2024-05-03 19:24:25 +01:00 committed by Andrew Tridgell
parent a8d1d2b330
commit c9eb8fb395
1 changed files with 28 additions and 0 deletions

View File

@ -36,6 +36,27 @@ jobs:
sudo apt-get -y install lua-check
./Tools/scripts/run_luacheck.sh
- name: Setup language server
shell: bash
run: |
sudo apt install -y curl
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
(echo; echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"') >> /github/home/.bashrc
source ~/.bashrc
brew install lua-language-server
- name: Generate docs md
shell: bash
run: |
source ~/.bashrc
./Tools/scripts/generate_lua_docs.sh
- name: Language server check
shell: bash
run: |
source ~/.bashrc
python ./Tools/scripts/run_lua_language_check.py
- name: copy docs
run: |
PATH="/github/home/.local/bin:$PATH"
@ -53,3 +74,10 @@ jobs:
run: |
PATH="/github/home/.local/bin:$PATH"
python ./libraries/AP_Scripting/tests/docs_check.py "./libraries/AP_Scripting/docs/docs.lua" "./libraries/AP_Scripting/docs/current_docs.lua"
- name: Upload docs
uses: actions/upload-artifact@v3
with:
name: Docs
path: ScriptingDocs.md
retention-days: 7