Update importedGuns.json #24
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update importedGuns.json | |
on: | |
schedule: | |
- cron: "0 0 * * *" | |
workflow_dispatch: | |
jobs: | |
update-importedguns: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- uses: pnpm/[email protected] | |
with: | |
version: 9 | |
- name: Install Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 22 | |
cache: "pnpm" | |
cache-dependency-path: ./packages/mtc-artillery/pnpm-lock.yaml | |
- name: Execute script | |
id: roblox-luau-execution | |
uses: grand-hawk/[email protected] | |
with: | |
roblox_api_key: ${{ secrets.ROBLOX_LUAU_EXECUTION_API_KEY }} | |
universe_id: "3221676855" | |
place_id: "8421780146" | |
luau_file: "./packages/mtc-artillery/scripts/exportProjectiles.luau" | |
output_file: "script-execution-output.json" | |
- name: Process JSON output | |
run: jq ".[0]" "./script-execution-output.json" > "./packages/mtc-artillery/src/config/importedGuns.json" | |
- name: Format | |
run: pnpm prettier "./src/config/importedGuns.json" -w | |
working-directory: ./packages/mtc-artillery | |
- name: Commit changes | |
uses: EndBug/add-and-commit@v9 | |
with: | |
message: "Update importedGuns.json" | |
add: "./packages/mtc-artillery/src/config/importedGuns.json" |