update #26
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: CI | |
'on': | |
- push | |
jobs: | |
bazel_build: | |
runs-on: ubuntu-18.04 | |
strategy: | |
matrix: | |
node: | |
- '12' | |
name: Node ${{ matrix.node }} sample | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: "${{ matrix.node }}" | |
- uses: actions/cache@v2 | |
id: yarn-cache | |
with: | |
path: | | |
node_modules | |
**/node_modules | |
key: "${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}" | |
restore-keys: "${{ runner.os }}-yarn-\n" | |
- uses: actions/cache@v2 | |
id: bazel-cache | |
with: | |
path: | | |
/home/runner/.cache/bazel | |
/home/runner/bazel_repository_cache | |
key: "${{ runner.os }}-bazel-${{ hashFiles('.bazelversion') }}-${{ hashFiles('WORKSPACE') }}-${{ hashFiles('**/yarn.lock') }}" | |
restore-keys: "${{ runner.os }}-bazel-\n" | |
- name: Setup bazel ci config | |
run: echo "import %workspace%/.github/bazel.rc" >> ./.bazelrc | |
- name: Installing project dependencies | |
run: yarn install --frozen-lockfile --non-interactive | |
- name: Setting up global Bazel binary | |
run: "./scripts/circleci/setup_bazel_binary.sh" | |
- run: yarn build | |
- name: Checking release output | |
run: | | |
pkg_json_version=$(node -pe "require('./package.json').version") | |
expected_version="${pkg_json_version}-sha-$(git rev-parse --short HEAD)" | |
yarn check-release-output ${expected_version} |