-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: automate gsheet publication (#299)
* feat: automate google sheets update * feat: automate google sheets update * feat: automate google sheets update * feat: automate google sheets update * build: pass secrets * build: update workflow * build: test google sheets step
- Loading branch information
Showing
13 changed files
with
452 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Google Sheets Sync | ||
|
||
on: | ||
workflow_dispatch: # This allows manual triggering from the GitHub Actions UI. | ||
|
||
jobs: | ||
refresh: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4 | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version-file: '.nvmrc' | ||
|
||
- name: Setup pnpm | ||
uses: pnpm/action-setup@v3 | ||
with: | ||
run_install: true | ||
|
||
- name: Update Google Sheets | ||
run: | | ||
pnpm start -v google-sheets | ||
env: | ||
GOOGLE_SHEET_ID: ${{ secrets.GOOGLE_SHEET_ID }} | ||
GOOGLE_CLIENT_EMAIL: ${{ secrets.GOOGLE_CLIENT_EMAIL }} | ||
GOOGLE_PRIVATE_KEY: ${{ secrets.GOOGLE_PRIVATE_KEY }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
node_modules/ | ||
dist/ | ||
temp/ | ||
temp/ | ||
|
||
config/.env | ||
credentials.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Google Sheets Publishing | ||
GOOGLE_SHEET_ID=<some sheet id> | ||
GOOGLE_CLIENT_EMAIL=<some client email> | ||
GOOGLE_PRIVATE_KEY=<some private key> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,16 +27,16 @@ | |
"@types/lodash": "4.17.0", | ||
"@types/node": "20.12.6", | ||
"commander": "12.0.0", | ||
"dotenv": "16.4.5", | ||
"googleapis": "134.0.0", | ||
"jsdom": "24.0.0", | ||
"lodash": "4.17.21", | ||
"puppeteer": "22.6.3", | ||
"ts-node": "10.9.2", | ||
"typescript": "5.4.4" | ||
}, | ||
|
||
"engines": { | ||
"node": "20" | ||
}, | ||
|
||
"packageManager": "[email protected]" | ||
} |
Oops, something went wrong.