Enrich candidate data with EC fields (age, DOB, family, address, photo) #7
This file contains hidden or 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: Validate Data | |
| on: | |
| pull_request: | |
| paths: | |
| - 'data/**/*.yml' | |
| - 'data/**/*.yaml' | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - 'data/**/*.yml' | |
| - 'data/**/*.yaml' | |
| jobs: | |
| validate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Validate YAML files | |
| run: npm run validate-data | |
| - name: Build JSON from YAML | |
| run: npm run build-data | |
| - name: Upload data artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: election-data | |
| path: .data-build/ | |
| retention-days: 7 |