-
Notifications
You must be signed in to change notification settings - Fork 6
40 lines (36 loc) · 1.05 KB
/
gen-whoami-table.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
name: "gen-whoami-table"
on:
workflow_dispatch:
push:
paths:
- 'whoami.yml'
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v3
with:
ref: main
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install Python dependencies
uses: py-actions/py-dependency-install@v4
with:
path: ".github/workflows/requirements.txt"
- name: Generate table
run: |
python3 .github/workflows/gen-whoami-table.py whoami.yml
- name: Commit changes
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
git add whoami.md
git commit -m "Update device WhoAmI table"
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
git push
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}