Update Metadata Entry List #28
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: Update Metadata Entry List | |
| on: | |
| workflow_dispatch: | |
| push: | |
| paths: | |
| - "jsonFiles/**" | |
| - "jsonFiles/*" | |
| - "jsonFiles" | |
| schedule: | |
| - cron: '0 0 */3 * *' # Weekly job to update the list every 3 days at midnight UTC | |
| jobs: | |
| collectNamesTo_csv: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.10' | |
| - name: Install dependencies | |
| run: pip install --upgrade pip | |
| - name: Collect Project Names to CSV | |
| run: python collectNamesTo_csv.py | |
| - name: Commit and Push Changes | |
| run: | | |
| git config --global user.name "GitHub Actions" | |
| git config --global user.email "github-actions@github.com" | |
| git add data/bioeco_list.csv | |
| git diff --cached --quiet || git commit -m "Updated list of metadata entries" | |
| git push |