Skip to content

Merge pull request #132 from scalyr/warning-cleanup #90

Merge pull request #132 from scalyr/warning-cleanup

Merge pull request #132 from scalyr/warning-cleanup #90

Workflow file for this run

name: CI
on:
push:
branches:
- master
pull_request:
branches:
- master
permissions:
contents: read
jobs:
frontend:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
# TODO This should install the latest LTS version,
# temporarily disabled for downstream dependencies
#node-version: 'lts/*'
node-version: 'lts/hydrogen' # v18
# Ref: https://github.com/actions/cache/blob/main/examples.md#node---yarn
- name: Get yarn cache path
id: yarn-cache-path
run: echo "::set-output name=path::$(yarn cache dir)"
- uses: actions/cache@v3
with:
path: ${{ steps.yarn-cache-path.outputs.path }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
# Not recommended to cache node_modules
# Ref: https://github.com/actions/cache/blob/main/examples.md#node---npm
- run: yarn install --frozen-lockfile
- run: yarn build
backend:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: 'stable'
# `mage format` would reformat files
- name: gofmt check
run: test -z "$(gofmt -l pkg)"
#- uses: magefile/mage-action@v2
# with:
# args: lint
- uses: golangci/golangci-lint-action@v3
with:
version: 'latest'
working-directory: pkg
- uses: magefile/mage-action@v2
with:
args: test
- uses: magefile/mage-action@v2
with:
args: buildall