1name: Native Component List app 2 3on: 4 workflow_dispatch: {} 5 pull_request: 6 branches: [master] 7 paths: 8 - .github/workflows/native-component-list.yml 9 - apps/native-component-list/** 10 - yarn.lock 11 push: 12 branches: [master] 13 paths: 14 - .github/workflows/native-component-list.yml 15 - apps/native-component-list/** 16 - yarn.lock 17 18jobs: 19 build: 20 runs-on: ubuntu-18.04 21 steps: 22 - uses: actions/checkout@v2 23 with: 24 submodules: true 25 - uses: actions/setup-node@v2-beta 26 with: 27 node-version: '12' 28 - name: Get yarn cache directory path 29 id: yarn-cache-dir-path 30 run: echo "::set-output name=dir::$(yarn cache dir)" 31 - uses: actions/cache@v1 32 with: 33 path: ${{ steps.yarn-cache-dir-path.outputs.dir }} 34 key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }} 35 restore-keys: | 36 ${{ runner.os }}-yarn- 37 - run: yarn install --frozen-lockfile 38 - run: yarn tsc 39 working-directory: apps/native-component-list 40 - run: yarn lint --max-warnings 0 41 working-directory: apps/native-component-list 42 - uses: 8398a7/action-slack@v3 43 if: failure() && (github.event.ref == 'refs/heads/master') 44 with: 45 channel: '#api' 46 status: ${{ job.status }} 47 author_name: native-component-list/build 48 fields: author,job,message,ref 49 env: 50 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 51 SLACK_WEBHOOK_URL: ${{ secrets.slack_webhook_api }} 52