Skip to content

Commit

Permalink
Create monthly-update.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
lubianat authored Jul 24, 2024
1 parent c94321b commit 5367dd6
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/monthly-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Monthly Update

on:
schedule:
- cron: '0 0 25 * *' # Runs at 00:00 on the 25th day of each month
workflow_dispatch: # Allows manual triggering for testing

jobs:
update:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r www/python/src/requirements.txt
- name: Run fetch_wikipedia_genes
run: python www/python/src/fetch_wikipedia_genes.py

- name: Run generate_gmt
run: python www/python/src/generate_gmt.py

- name: Commit changes
run: |
git config --local user.email "[email protected]"
git config --local user.name "Your Name"
git add .
git commit -m "Monthly update: fetch genes and generate GMT"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Bump version and push
run: |
pip install bump2version
bump2version minor --tag
git push --follow-tags
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 5367dd6

Please sign in to comment.