-
-
Notifications
You must be signed in to change notification settings - Fork 7
109 lines (107 loc) · 3.11 KB
/
scrape.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
name: Scrape latest help
on:
workflow_dispatch:
schedule:
- cron: '1 15 * * *'
jobs:
scheduled:
runs-on: ubuntu-latest
steps:
- name: Check out this repo
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Configure Python with pip cache
uses: actions/setup-python@v2
with:
python-version: '3.10'
cache: 'pip'
- uses: actions/setup-node@v2
with:
node-version: '14'
cache: 'npm'
cache-dependency-path: '**/.github/workflows/*.yml'
- name: Install Python dependencies
run: pip install -U -r requirements.txt
- name: Configure Git for commits
run: |-
git config user.name "Automated"
git config user.email "actions@users.noreply.github.com"
- name: Commit and push if it changed
run: |-
git add -A
timestamp=$(date -u)
git commit -m "sqlite-utils: ${timestamp}" || exit 0
git push
- name: Compile latest SQLite
run: |-
cd /tmp
git clone --depth 1 https://github.com/sqlite/sqlite
mkdir /tmp/bld
cd /tmp/bld
../sqlite/configure
make sqlite3.c
gcc shell.c sqlite3.c -lpthread -ldl
./a.out --version
- name: Scrape sqlite3 help
run: |-
python sqlite3_help.py /tmp/bld/a.out > sqlite3-help.md
- name: Commit and push if it changed
run: |-
git add -A
timestamp=$(date -u)
git commit -m "sqlite3: ${timestamp}" || exit 0
git push
- name: Scrape GitHub GraphQL API schema
run: |-
mkdir -p github
npx get-graphql-schema https://api.github.com/graphql \
-h 'Authorization=Bearer ${{ secrets.GITHUB_TOKEN }}' > github/github.graphql
- name: Commit and push if it changed
run: |-
git add -A
timestamp=$(date -u)
git commit -m "GitHub: ${timestamp}" || exit 0
git push
- name: Scrape Vercel
run: |-
python vercel_commands.py
- name: Commit and push if it changed
run: |-
git add -A
timestamp=$(date -u)
git commit -m "Vercel: ${timestamp}" || exit 0
git push
- name: Scrape Azure
run: |-
sh azure.sh
- name: Commit and push if it changed
run: |-
git add -A
timestamp=$(date -u)
git commit -m "Azure: ${timestamp}" || exit 0
git push
- name: Scrape Fly
run: |-
./fly.sh
# Grab the GraphQL schema too
npx get-graphql-schema https://api.fly.io/graphql > flyctl/fly.graphql
- name: Commit and push if it changed
run: |-
git add -A
timestamp=$(date -u)
git commit -m "Fly: ${timestamp}" || exit 0
git push
- name: Scrape AWS
run: |-
python -m pip install -U awscli
python -m awscli --version > aws/aws-version.txt
cat aws/aws-version.txt
python aws_commands.py
- name: Commit and push if it changed
run: |-
git add -A
timestamp=$(date -u)
git commit -m "AWS: ${timestamp}" || exit 0
git pull --rebase
git push