@@ -25,6 +25,31 @@ permissions:
2525 contents : write # Required for repository access and tagging
2626
2727jobs :
28+ validate :
29+ name : Validate CI and ITS
30+ runs-on : github-ubuntu-latest-s
31+ steps :
32+ - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
33+ with :
34+ fetch-depth : 0 # Fetch all history for git operations
35+ - uses : jdx/mise-action@146a28175021df8ca24f8ee1828cc2a60f980bd5 # v3.5.1
36+ with :
37+ version : 2025.7.12
38+ - name : Cache dependencies
39+ uses : SonarSource/ci-github-actions/cache@v1
40+ with :
41+ path : |
42+ node_modules
43+ key : cache-${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
44+ - name : Install dependencies
45+ run : bash scripts/install.sh
46+ - name : Validate generated ITS
47+ run : |
48+ npm run generate-its
49+ git diff --exit-code
50+ - name : Validate CI
51+ run : npm run validate-ci
52+
2853 get-build-number :
2954 name : Preload build number
3055 runs-on : github-ubuntu-latest-s
@@ -33,24 +58,24 @@ jobs:
3358 contents : read
3459 steps :
3560 - uses : SonarSource/ci-github-actions/get-build-number@v1
61+
3662 build :
3763 needs :
64+ - validate
3865 - get-build-number
39- runs-on : github-ubuntu-latest-s # Using custom GitHub-hosted runner for public repo
66+ runs-on : github-ubuntu-latest-s
4067 name : Build and Test
4168 steps :
4269 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
4370 with :
4471 fetch-depth : 0 # Fetch all history for git operations
45-
4672 - uses : jdx/mise-action@146a28175021df8ca24f8ee1828cc2a60f980bd5 # v3.5.1
4773 with :
4874 version : 2025.7.12
4975 - uses : SonarSource/ci-github-actions/config-npm@v1
5076 id : config
5177 with :
5278 artifactory-reader-role : private-reader
53- # Fetch vault secrets for build
5479 - name : Vault
5580 id : secrets
5681 uses : SonarSource/vault-action-wrapper@v3 # v3.1.0
7398 # Install dependencies
7499 - name : Install dependencies
75100 run : bash scripts/install.sh
76-
77- # Validate generated ITS are up-to-date
78- - name : Validate generated ITS
79- run : |
80- npm run generate-its
81- git diff --exit-code
82- - name : Validate CI
83- run : npm run validate-ci
84101 - name : Build
85102 run : npm run build
86103 - name : Run SonarQube Analysis
@@ -99,14 +116,14 @@ jobs:
99116
100117 check_size :
101118 needs :
119+ - validate
102120 - get-build-number
103121 runs-on : github-ubuntu-latest-s # Using custom GitHub-hosted runner for public repo
104122 name : Check Extension Size
105123 env :
106124 MAX_FILE_SIZE_MB : 40
107125 steps :
108126 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
109-
110127 - uses : jdx/mise-action@146a28175021df8ca24f8ee1828cc2a60f980bd5 # v3.5.1
111128 with :
112129 version : 2025.7.12
0 commit comments