Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build-and-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ jobs:

- name: Install and Build
run: |
yarn install
yarn build --base=/cssColorNameFinder/
npm ci
npm run build -- --base=/cssColorNameFinder/
- name: Deploy 🚀
uses: JamesIves/github-pages-deploy-action@releases/v3
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/commitlint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ jobs:
- name: Set up node
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: '24'
- name: Install
run: yarn install --frozen-lockfile
run: npm ci
- name: Lint commits
run: yarn commitlint --verbose --from `git log -1 HEAD^1 --pretty=format:'%H'`
run: npx commitlint --from f0082a4
28 changes: 28 additions & 0 deletions .github/workflows/sonarqube.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
on:
# Trigger analysis when pushing to your main branches, and when creating a pull request.
push:
branches:
- main
- master
- develop
- 'releases/**'
pull_request:
types: [opened, synchronize, reopened]

name: SonarQube Main Workflow
jobs:
sonarqube:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
# Disabling shallow clones is recommended for improving the relevancy of reporting
fetch-depth: 0
- name: Install
run: npm ci
- name: Test
run: npm run test:unit --coverage
- name: SonarQube Scan
uses: SonarSource/sonarqube-scan-action@a31c9398be7ace6bbfaf30c0bd5d415f843d45e9 # v7.0.0
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
32 changes: 3 additions & 29 deletions .github/workflows/test-and-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,34 +12,8 @@ jobs:
- name: Set up node
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: '24'
- name: Install
run: yarn install --frozen-lockfile
run: npm ci
- name: Test
run: yarn test

unit-test-and-sonar:
name: Unit tests and coverage for sonar
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up node
uses: actions/setup-node@v3
with:
node-version: '16.x'
- name: Install
run: yarn install --frozen-lockfile
- name: Test
run: yarn test:unit --coverage
- name: Setup Sonar Scanner
uses: warchant/setup-sonar-scanner@v3
- name: Run sonarqube
env:
# to get access to secrets.SONAR_TOKEN, provide GITHUB_TOKEN
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: sonar-scanner
-Dsonar.login=${{ secrets.SONAR_TOKEN }}
-Dsonar.host.url=https://sonarcloud.io/
run: npm run test
3 changes: 0 additions & 3 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx --no-install commitlint --edit "" || true
5 changes: 1 addition & 4 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

yarn lint-staged
npx lint-staged
Loading
Loading