Skip to content

feat: workflow check db #1

feat: workflow check db

feat: workflow check db #1

Workflow file for this run

name: Check DB
on:
pull_request:
branches: [main]
types: [opened, synchronize, reopened, closed]
paths:
- "db/TDesign.db"
- "packages/scripts/api.json"
jobs:
check-db:
runs-on: ubuntu-latest
if: >
github.event_name == 'pull_request' &&
github.event.pull_request.merged == false
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Install Dependencies
run: npm install
- name: Start Service
run: npm run dev
- name: Update api.json
run: npm run api:download
- name: Check Diff
run: |

Check failure on line 29 in .github/workflows/check-db.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/check-db.yml

Invalid workflow file

You have an error in your yaml syntax on line 29
git diff --quiet
DIFF_EXIT_CODE=$?
if [ $DIFF_EXIT_CODE -eq 1 ]; then
echo "TDesign.db and api.json data inconsistency. Workflow will fail."
exit 1
fi