-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (44 loc) · 1.32 KB
/
youtube.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
name: Sync - YouTube
on:
workflow_dispatch:
push:
branches:
- main
jobs:
capture:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- uses: pnpm/action-setup@v2.2.4
id: pnpm-install
with:
version: 7
run_install: false
- uses: actions/cache@v3
with:
path: |
node_modules
~/.local/share/pnpm/store/v3
key: ${{ runner.OS }}-x86-node18-pnpm7-svelte-${{ inputs.hash }}-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.OS }}-x86-node18-pnpm7-svelte-${{ inputs.hash }}-${{ env.cache-name }}-
${{ runner.OS }}-x86-node18-pnpm7-svelte-${{ inputs.hash }}-
- run: pnpm -r i --prefer-offline --frozen-lockfile
- run: pnpm capture
- name: Write secret file
run: |
mkdir -p .data
echo "$GOOGLE_CLIENT_JSON" > .data/google_client_secret.json
env:
GOOGLE_CLIENT_JSON: ${{ secrets.GOOGLE_CLIENT_JSON }}
- run: pnpm push
env:
GOOGLE_REFRESH_TOKEN: ${{ secrets.GOOGLE_REFRESH_TOKEN }}
- uses: actions/upload-artifact@v3
with:
name: artifact-dist
path: dist
retention-days: 1