diff --git a/.github/workflows/temp-full-safe-modularization.yml b/.github/workflows/temp-full-safe-modularization.yml new file mode 100644 index 0000000..f4c1cb9 --- /dev/null +++ b/.github/workflows/temp-full-safe-modularization.yml @@ -0,0 +1,44 @@ +name: Temporary full safe modularization + +on: + push: + paths: + - tools/apply_full_safe_modularization.py + - .github/workflows/temp-full-safe-modularization.yml + workflow_dispatch: + +permissions: + contents: write + +jobs: + modularize: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Install project dependencies + run: | + python -m pip install --upgrade pip + if [ -f requirements.txt ]; then python -m pip install -r requirements.txt; fi + python -m pip install filelock + - name: Apply safe modularization + run: python tools/apply_full_safe_modularization.py + - name: Verify Python syntax + run: python -m compileall -q . + - name: Run full unit test suite + run: python -m unittest discover -s tests -p 'test_*.py' + - name: Commit modularized source and cleanup + run: | + git config user.name "github-actions[bot]" + git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + git rm -f \ + tools/apply_full_safe_modularization.py \ + tools/build_refactor_inventory.py \ + refactor_inventory.json \ + .github/workflows/temp-refactor-inventory.yml \ + .github/workflows/temp-full-safe-modularization.yml + git add -A + git commit -m "refactor: modularize registration runtime safely" + git push