https://pvzm.net/ to play [Read-only GitHub mirror] pvzm.net
modded vs pvz plants-vs-zombies plantsvszombies javascript online zombie noads jspvz pvzm game plants plant
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix workflow

authored by

Clay and committed by
GitHub
2d412dbc 0e4f0db2

+11 -11
+11 -11
.github/workflows/main.yml
··· 27 27 fetch-depth: 1 28 28 29 29 - name: Setup Node.js & pnpm 30 - uses: actions/setup-node@v3 30 + uses: actions/setup-node@v4 31 31 with: 32 32 node-version: "lts/*" 33 33 ··· 42 42 with: 43 43 path: | 44 44 ~/.local/share/pnpm/global 45 - ~/.local/share/pnpm/store 46 - key: pnpm-global-${{ hashFiles('.github/workflows/main.yml') }} 45 + key: pnpm-global-${{ hashFiles('pnpm-lock.yaml') }} 47 46 restore-keys: pnpm-global- 48 47 49 48 - name: Install dependencies 50 - run: pnpm add -g oxlint oxfmt esbuild html-minifier-terser wrangler 49 + run: pnpm add -g oxlint oxfmt esbuild html-minifier-terser 51 50 52 51 - name: Lint, format & version stamp 53 52 run: | 54 - pnpm run fix || true 53 + pnpm run fix # fix 5: removed `|| true`, lint failures now fail build 55 54 pnpm oxfmt --write . "**/*.{js,md,html,css,yml}" 56 55 echo "${{ github.sha }}" > game/images/Zombies/CX/v.html 57 56 ··· 71 70 - name: Bundle & minify all assets 72 71 run: | 73 72 esbuild game/js/CPlants.js \ 74 - --bundle --minify --sourcemap --sources-content=true \ 73 + --bundle --minify --sourcemap \ # fix 7: removed --sources-content=true 75 74 --outfile=game/js/CPlants.js --allow-overwrite 76 75 77 - esbuild $(find . -type f \( -name "*.js" -o -name "*.css" \) \ 78 - -not -path "./node_modules/*" -not -name "CPlants.js") \ 79 - --minify --sourcemap --sources-content=true \ 80 - --outdir=. --allow-overwrite & 76 + find . -type f -name "*.js" -o -name "*.css" \ # fix 6: xargs to avoid ARG_MAX 77 + -not -path "./node_modules/*" -not -name "CPlants.js" | \ 78 + xargs -P4 -I{} esbuild {} \ 79 + --minify --sourcemap \ 80 + --outdir=. --allow-overwrite & 81 81 82 82 find . -type f -name "*.html" -not -path "./node_modules/*" | \ 83 83 xargs -P4 -I{} html-minifier-terser \ ··· 91 91 with: 92 92 apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} 93 93 accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} 94 - command: pages deploy . --project-name=pvz --branch=${{ github.head_ref || github.ref_name }} 94 + command: pages deploy . --project-name=pvz --branch=${{ github.ref_name }} 95 95 gitHubToken: ${{ secrets.GITHUB_TOKEN }}