-
Notifications
You must be signed in to change notification settings - Fork 1
48 lines (41 loc) · 1.21 KB
/
feed_bot.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Create PR for RSS/Atom feeds
on:
schedule:
- cron: "00 00 * * *"
workflow_dispatch:
inputs:
days:
description: "Number of days before today to check for new feeds"
required: false
default: "14"
jobs:
feed-bot:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt
- name: Generate a token
id: generate-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.APP_ID }}
private-key: ${{ secrets.APP_PRIVATE_KEY }}
owner: "usegalaxy-eu"
repositories: "galaxy-social"
- name: Run python script
env:
GALAXY_SOCIAL_BOT_TOKEN: ${{ steps.generate-token.outputs.token }}
REPO: "usegalaxy-eu/galaxy-social"
DAYS: ${{ github.event.inputs.days || '14' }}
run: python -u app/feed_bot.py