-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (37 loc) · 1.22 KB
/
sync.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
name: Synchronize
on:
workflow_dispatch:
schedule:
- cron: '0 3,6,9,12,15 * * *'
jobs:
sync:
name: Synchronize
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up
uses: ./.github/actions/setup
- name: Post to Mastodon
run: bin/publish --confirm --social=mastodon
env:
MASTODON_ACCESS_TOKEN: ${{ secrets.MASTODON_ACCESS_TOKEN }}
FACEBOOK_PAGE_ACCESS_TOKEN: ${{ secrets.FACEBOOK_PAGE_ACCESS_TOKEN }}
FIREBASE_API_KEY: ${{ secrets.FIREBASE_API_KEY }}
- name: Post to Facebook
run: bin/publish --confirm --social=facebook
env:
MASTODON_ACCESS_TOKEN: ${{ secrets.MASTODON_ACCESS_TOKEN }}
FACEBOOK_PAGE_ACCESS_TOKEN: ${{ secrets.FACEBOOK_PAGE_ACCESS_TOKEN }}
FIREBASE_API_KEY: ${{ secrets.FIREBASE_API_KEY }}
- uses: stefanzweifel/git-auto-commit-action@v4
if: always()
with:
commit_message: Update state file
commit_user_name: 'dtinth-bot'
commit_user_email: '[email protected]'
- name: Dump the new state
if: always()
run: cat state.yaml
permissions:
contents: write