name: Cookie Handler GDPR
on: [push, pull_request]

jobs:
  install-and-check:
    name: Install and QA checks
    runs-on: self-hosted
    strategy:
      matrix:
        node-version: [12.x]
    steps:
      - uses: actions/checkout@master
        with:
          fetch-depth: 1

      - name: Use Node.js ${{ matrix.node-version }}
        uses: actions/setup-node@master
        with:
          node-version: ${{ matrix.node-version }}

      - name: Install
        run: yarn

      - name: QA Review
        run: |
          yarn lint:check
          yarn prettier:check
        env:
          CI: true

      - name: Slack Notification Install and QA checks
        if: always()
        uses: 8398a7/action-slack@v2
        with:
          status: ${{ job.status }}
          author_name: ${{ github.repository }}
          fields: repo,message,action,author
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
