Skip to content

Bump @types/node from 20.14.8 to 20.14.10 in /scripts #36

Bump @types/node from 20.14.8 to 20.14.10 in /scripts

Bump @types/node from 20.14.8 to 20.14.10 in /scripts #36

Workflow file for this run

name: Validate Mod Json
on:
# Runs on pushes targeting the default branch
pull_request:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
# Single deploy job since we're just deploying
test:
name: pr-check-mods
runs-on: ubuntu-latest
if: (github.event.issue.pull_request && github.event_name == 'issue_comment' && github.event.comment.body == '/check') || github.event_name == 'pull_request'
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: main
- uses: actions/setup-node@v4
with:
node-version: 20
- name: Get changed files
id: get_changed_files
run: |
curl --silent "https://api.github.com/repos/dantheman827/bsqmods/pulls/${{ github.event.pull_request.number }}/files" | jq -r '.[].filename' > changed-files.txt
- name: Get the mods folder of the PR
id: download_mods_json
run: |
rm -r mods
wget "https://api.github.com/repos/dantheman827/bsqmods/tarball/pull/${{ github.event.pull_request.number }}/head" -qO - | tar -xzvf - --strip-components=1 --wildcards '*/mods/'
- name: Validate json
run: |
cd scripts
npm install
npx tsx ./pr-check.ts