-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (47 loc) · 1.47 KB
/
mastodon.yaml
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
49
50
51
52
53
54
55
name: "Mastodon toot"
on:
workflow_dispatch:
schedule:
- cron: "0 */3 * * *"
jobs:
run:
name: Run
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- id: setup-python
name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
cache: 'pipenv'
- id: install-pipenv
name: Install pipenv
run: curl https://raw.githubusercontent.com/pypa/pipenv/master/get-pipenv.py | python
shell: bash
- id: install-python-dependencies
name: Install Python dependencies
run: pipenv sync --dev
shell: bash
- id: mastodon
name: Send toot
run: make toot
shell: bash
env:
MASTODON_CLIENT_KEY: ${{ secrets.MASTODON_CLIENT_KEY }}
MASTODON_CLIENT_SECRET: ${{ secrets.MASTODON_CLIENT_SECRET }}
MASTODON_ACCESS_TOKEN: ${{ secrets.MASTODON_ACCESS_TOKEN }}
- name: Datestamp
run: date > oldlaphotos/timestamp.txt
shell: bash
- name: Commit results
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "actions@github.com"
git config pull.rebase false
git status
git pull origin $GITHUB_REF
git add ./oldlaphotos
git commit -m "Ping" --author="palewire <palewire@users.noreply.github.com>" && git push || true
shell: bash