feat: upgrade to Node v20 #526
Workflow file for this run
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
# NOTE: if you want to use this file as a template, make sure to replace 'main' in line 21 | |
# with your repository's default branch (in case you changed it to something other than 'main') | |
on: [push, pull_request] | |
name: Twitter, together! | |
jobs: | |
preview: | |
name: Preview | |
if: github.event_name == 'pull_request' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version-file: .nvmrc | |
- run: npm ci | |
- run: npm run build | |
- name: Preview | |
uses: ./ | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
tweet: | |
name: Tweet | |
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version-file: .nvmrc | |
- run: npm ci | |
- run: npm run build | |
- name: Tweet | |
uses: ./ | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
TWITTER_ACCESS_TOKEN: ${{ secrets.TWITTER_ACCESS_TOKEN }} | |
TWITTER_ACCESS_TOKEN_SECRET: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }} | |
TWITTER_API_KEY: ${{ secrets.TWITTER_API_KEY }} | |
TWITTER_API_SECRET_KEY: ${{ secrets.TWITTER_API_SECRET_KEY }} |