diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index af647b29f..4617d56ad 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -3,32 +3,32 @@ name: CI on: [push] jobs: - build: - runs-on: ubuntu-latest + build: + runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - # might be required for sonar to work correctly - with: - fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis - - name: Use Node.js - uses: actions/setup-node@v1 - with: - node-version: "12.x" + steps: + - uses: actions/checkout@v2 + # might be required for sonar to work correctly + with: + fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis + - name: Use Node.js + uses: actions/setup-node@v1 + with: + node-version: "16.x" - - uses: actions/cache@v2 - with: - path: ~/.npm - key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} - restore-keys: | - ${{ runner.os }}-node- + - uses: actions/cache@v2 + with: + path: ~/.npm + key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} + restore-keys: | + ${{ runner.os }}-node- - - run: npm ci - - run: npm run bootstrap - - run: npm run build - - run: npm run test:cov - - name: SonarCloud Scan - uses: SonarSource/sonarcloud-github-action@master - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + - run: npm ci + - run: npm run bootstrap + - run: npm run build + - run: npm run test:cov + - name: SonarCloud Scan + uses: SonarSource/sonarcloud-github-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}