Skip to content

🔄retry to 🛠fix 🪲bug #28

🔄retry to 🛠fix 🪲bug

🔄retry to 🛠fix 🪲bug #28

name: Process GLB & JSX Files
on:
push:
branches: ["main"]
workflow_dispatch:
jobs:
process-files:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
- name: Create Logs Directory
run: mkdir -p logs
- name: Detect Missing JSX Files
run: bash scripts/detect_missing.sh
- name: Convert GLB Files to JSX
run: bash scripts/convert.sh
- name: Update JSX Files
run: bash scripts/update_jsx.sh ${{ github.repository }} main
- name: Handle Conversion Errors
run: bash scripts/handle_errors.sh
- name: Cleanup Orphaned JSX Files
run: bash scripts/cleanup_orphan_jsx.sh
- name: Build Webpack Bundles
run: bash scripts/webpack_build.sh
- name: Cleanup Orphaned Bundles
run: bash scripts/cleanup_bundles.sh
- name: Check Webpack Error Log
run: |
if [ -s scripts/error.txt ]; then
echo "Webpack build failed. See scripts/error.txt for details."
exit 1
fi
- name: Upload Webpack Error Log (if any)
uses: actions/upload-artifact@v4
if: failure()
with:
name: webpack-error-log
path: scripts/error.txt
- name: Commit and Push Changes
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
bash scripts/commit_push.sh