fixed Busted support (hopefully)

This commit is contained in:
FatalErr42O 2023-09-09 11:23:20 -07:00
parent ae5c7046e8
commit 2b81bab520
2 changed files with 1 additions and 32 deletions

View File

@ -1,31 +0,0 @@
# Based on https://gist.github.com/domenic/ec8b0fc8ab45f39403dd
name: Documentation
on:
pull_request: # Build on pull requests to ensure they don't break docs.
branches:
- master
push: # We'll only push new docs when master is updated (see below).
branches:
- master
jobs:
build:
name: Build Docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Lua
uses: leafo/gh-actions-lua@v8
with:
luaVersion: 5.4
- name: Setup Lua Rocks
uses: leafo/gh-actions-luarocks@v4
- name: Setup and run ldoc
run: bash ./doc/install_and_build_docs
- name: Deploy
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./doc/out

View File

@ -61,12 +61,12 @@ local modpath = minetest.get_modpath("mtul_cpml")
local loaded_modules = {}
local old_require = require --just in case require is present (aka it's an insecure environment)
local ie = minetest.request_insecure_environment()
local old_package_path
--if require isn't present, allow us to load the modules through hackish means
--there's like 100s of require calls, it'd be insane to replace them. If you're farmiliar with require, the goal should be obvious.
--modules is the path to modules
local old_package_path
if not ie then
--if an insecure environment cannot be loaded, then we basically change how require works temporarily, so modules (which is referenced in all CPML files on require() has to be changed)
modules = modpath.."/modules/"