-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (35 loc) · 922 Bytes
/
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
name: Scrape
on:
schedule:
- cron: "0 9,18 * * *"
workflow_dispatch:
jobs:
scrape:
name: Scrape NASA Search API
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version-file: ".nvmrc"
cache: npm
- run: npm ci
- name: Run scraper scripts
run: node ./lib/scraper.js
- name: Commit and push changed files
run: |
git diff
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
git config --global user.name 'github-actions[bot]'
git add -A
git commit -m "🤖 Automated update (`date +%FT%T%z`)" || exit 0
git push
build:
name: Build
permissions:
id-token: write
pages: write
needs: scrape
uses: ./.github/workflows/build.yml