Commit 3677ba96 authored by tom goriunov's avatar tom goriunov Committed by GitHub

Merge pull request #243 from blockscout/workflow-enh

workflow enhancements
parents b7719076 4f81820f
name: Run code checks name: Linters
on: [pull_request] on:
pull_request:
push:
branches:
- main
jobs: jobs:
check_code: check_code:
name: Check code name: Run code checks
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
cache: 'yarn'
- name: Install dependencies - name: Install dependencies
run: yarn run: yarn install --frozen-lockfile
- name: Run ESLint - name: Run ESLint
run: yarn lint:eslint run: yarn lint:eslint
- name: Compile TypeScript - name: Compile TypeScript
......
...@@ -11,11 +11,12 @@ jobs: ...@@ -11,11 +11,12 @@ jobs:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
with: with:
lfs: 'true' lfs: 'true'
- uses: actions/setup-node@v2 - uses: actions/setup-node@v3
with: with:
node-version: '16' node-version: '16'
cache: 'yarn'
- name: Install dependencies - name: Install dependencies
run: yarn run: yarn install --frozen-lockfile
- name: Run your tests - name: Run your tests
run: HOME=/root yarn test-ct run: HOME=/root yarn test-ct
- name: Upload test results - name: Upload test results
......
name: Test workflow
on:
workflow_run:
workflows: ["Linters"]
types:
- completed
jobs:
on-success:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
name: Test depended workflow
runs-on: ubuntu-latest
steps:
- name: Print result
run: echo Success
on-error:
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
name: Test depended workflow
runs-on: ubuntu-latest
steps:
- name: Print result
run: echo Failure
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment