Update to Node.js v18 #46
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
--- | |
name: format | |
on: | |
pull_request: | |
branches: | |
- master | |
workflow_dispatch: {} | |
repository_dispatch: | |
types: | |
- format | |
jobs: | |
fix: | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
ref: ${{ github.head_ref }} | |
token: ${{ secrets.GH_TOKEN }} | |
- name: Import GPG key | |
uses: crazy-max/ghaction-import-gpg@v4 | |
id: import_gpg | |
with: | |
git_user_signingkey: true | |
git_commit_gpgsign: true | |
git_committer_name: ${{ secrets.GIT_USER_NAME }} | |
git_committer_email: ${{ secrets.GIT_USER_EMAIL }} | |
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }} | |
passphrase: ${{ secrets.GPG_PASSPHRASE }} | |
- name: Setup Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '18' | |
- name: Get yarn cache directory | |
id: yarn-cache-dir | |
run: echo "::set-output name=dir::$(yarn cache dir)" | |
- name: Yarn cache | |
uses: actions/cache@v2 | |
with: | |
path: ${{ steps.yarn-cache-dir.outputs.dir }} | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- name: Node modules cache | |
uses: actions/cache@v2 | |
with: | |
path: node_modules | |
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-node_modules-${{ hashFiles('**/yarn.lock') }} | |
- name: Install dependencies | |
run: yarn install --frozen-lockfile --non-interactive | |
- name: Format | |
run: yarn run format | |
- name: Commit | |
uses: stefanzweifel/git-auto-commit-action@v4 | |
with: | |
commit_message: Run format | |
commit_user_name: ${{ secrets.GIT_USER_NAME }} | |
commit_user_email: ${{ secrets.GIT_USER_EMAIL }} | |
commit_author: ${{ secrets.GIT_USER_NAME }} <${{ secrets.GIT_USER_EMAIL }}> |