Merge pull request #96 from ap-70/cat_data_backup #138
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: JSON Validation | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
validate_json: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Install jsonlint | |
run: npm install -g jsonlint | |
- name: Validate JSON | |
run: | | |
jsonlint -q plugins.json | |
- name: Check JSON validation result | |
run: | | |
if [ $? -ne 0 ]; then | |
echo "Invalid JSON. Merging or pushing is not allowed." | |
exit 1 | |
fi |