mirror of
https://github.com/gradle/actions.git
synced 2025-08-20 16:41:28 +08:00
Add npm build scans (#517)
This commit is contained in:
commit
52d4223bcd
16
.github/workflows/ci-check-and-unit-test.yml
vendored
16
.github/workflows/ci-check-and-unit-test.yml
vendored
@ -15,6 +15,7 @@ permissions:
|
|||||||
jobs:
|
jobs:
|
||||||
check-format-and-unit-test:
|
check-format-and-unit-test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout sources
|
- name: Checkout sources
|
||||||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
||||||
@ -31,13 +32,26 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
gradle-version: "8.12"
|
gradle-version: "8.12"
|
||||||
|
|
||||||
- name: Check formatting and compile
|
- name: Install npm dependencies
|
||||||
run: |
|
run: |
|
||||||
npm clean-install
|
npm clean-install
|
||||||
|
working-directory: sources
|
||||||
|
|
||||||
|
- name: Check formatting and compile
|
||||||
|
run: |
|
||||||
npm run check
|
npm run check
|
||||||
npm run compile
|
npm run compile
|
||||||
working-directory: sources
|
working-directory: sources
|
||||||
|
env:
|
||||||
|
NODE_OPTIONS: '-r @gradle/develocity-agent/preload'
|
||||||
|
DEVELOCITY_URL: 'https://ge.solutions-team.gradle.com'
|
||||||
|
DEVELOCITY_ACCESS_KEY: '${{ secrets.DV_SOLUTIONS_ACCESS_KEY }}'
|
||||||
|
|
||||||
- name: Run unit tests
|
- name: Run unit tests
|
||||||
run: |
|
run: |
|
||||||
npm test
|
npm test
|
||||||
working-directory: sources
|
working-directory: sources
|
||||||
|
env:
|
||||||
|
NODE_OPTIONS: '-r @gradle/develocity-agent/preload'
|
||||||
|
DEVELOCITY_URL: 'https://ge.solutions-team.gradle.com'
|
||||||
|
DEVELOCITY_ACCESS_KEY: '${{ secrets.DV_SOLUTIONS_ACCESS_KEY }}'
|
||||||
|
6
.github/workflows/ci-update-dist.yml
vendored
6
.github/workflows/ci-update-dist.yml
vendored
@ -39,7 +39,11 @@ jobs:
|
|||||||
npm run check
|
npm run check
|
||||||
npm run compile
|
npm run compile
|
||||||
working-directory: sources
|
working-directory: sources
|
||||||
|
env:
|
||||||
|
NODE_OPTIONS: '-r @gradle/develocity-agent/preload'
|
||||||
|
DEVELOCITY_URL: https://ge.solutions-team.gradle.com
|
||||||
|
DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}
|
||||||
|
|
||||||
- name: Copy the generated sources/dist directory to the top-level dist
|
- name: Copy the generated sources/dist directory to the top-level dist
|
||||||
run: |
|
run: |
|
||||||
cp -r sources/dist .
|
cp -r sources/dist .
|
||||||
|
6
build
6
build
@ -2,6 +2,12 @@
|
|||||||
|
|
||||||
cd sources
|
cd sources
|
||||||
|
|
||||||
|
if [[ -f ~/.gradle/develocity/keys.properties ]]; then
|
||||||
|
export NODE_OPTIONS='-r @gradle/develocity-agent/preload'
|
||||||
|
export DEVELOCITY_URL=https://ge.solutions-team.gradle.com
|
||||||
|
export DEVELOCITY_ACCESS_KEY=$(paste -sd ';' ~/.gradle/develocity/keys.properties)
|
||||||
|
fi
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
all)
|
all)
|
||||||
npm run all
|
npm run all
|
||||||
|
16
sources/package-lock.json
generated
16
sources/package-lock.json
generated
@ -28,6 +28,7 @@
|
|||||||
"which": "5.0.0"
|
"which": "5.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@gradle/develocity-agent": "https://develocity-npm-pkgs.gradle.com/gradle-develocity-agent-0.9.0.tgz",
|
||||||
"@types/jest": "29.5.14",
|
"@types/jest": "29.5.14",
|
||||||
"@types/node": "20.17.14",
|
"@types/node": "20.17.14",
|
||||||
"@types/unzipper": "0.10.10",
|
"@types/unzipper": "0.10.10",
|
||||||
@ -1246,6 +1247,16 @@
|
|||||||
"integrity": "sha512-gIhjdJp/c2beaIWWIlsXdqXVRUz3r2BxBCpfz/F3JXHvSAQ1paMYjLH+maEATtENg+k5eLV7gA+9yPp762ieuw==",
|
"integrity": "sha512-gIhjdJp/c2beaIWWIlsXdqXVRUz3r2BxBCpfz/F3JXHvSAQ1paMYjLH+maEATtENg+k5eLV7gA+9yPp762ieuw==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
|
"node_modules/@gradle/develocity-agent": {
|
||||||
|
"version": "0.9.0",
|
||||||
|
"resolved": "https://develocity-npm-pkgs.gradle.com/gradle-develocity-agent-0.9.0.tgz",
|
||||||
|
"integrity": "sha512-uqCelicA2CzdvuYqix7sxdLUUkN6YdqfKZQewaSYYUhWi19OLlJeaMYzFMMEfPRqJ0/8LSt+KI228Lvlk+vZ0A==",
|
||||||
|
"dev": true,
|
||||||
|
"license": "SEE LICENSE AT https://gradle.com/help/legal-terms-of-use",
|
||||||
|
"engines": {
|
||||||
|
"node": ">=18.20.5"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@humanwhocodes/config-array": {
|
"node_modules/@humanwhocodes/config-array": {
|
||||||
"version": "0.13.0",
|
"version": "0.13.0",
|
||||||
"resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.13.0.tgz",
|
"resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.13.0.tgz",
|
||||||
@ -11163,6 +11174,11 @@
|
|||||||
"integrity": "sha512-gIhjdJp/c2beaIWWIlsXdqXVRUz3r2BxBCpfz/F3JXHvSAQ1paMYjLH+maEATtENg+k5eLV7gA+9yPp762ieuw==",
|
"integrity": "sha512-gIhjdJp/c2beaIWWIlsXdqXVRUz3r2BxBCpfz/F3JXHvSAQ1paMYjLH+maEATtENg+k5eLV7gA+9yPp762ieuw==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
|
"@gradle/develocity-agent": {
|
||||||
|
"version": "https://develocity-npm-pkgs.gradle.com/gradle-develocity-agent-0.9.0.tgz",
|
||||||
|
"integrity": "sha512-uqCelicA2CzdvuYqix7sxdLUUkN6YdqfKZQewaSYYUhWi19OLlJeaMYzFMMEfPRqJ0/8LSt+KI228Lvlk+vZ0A==",
|
||||||
|
"dev": true
|
||||||
|
},
|
||||||
"@humanwhocodes/config-array": {
|
"@humanwhocodes/config-array": {
|
||||||
"version": "0.13.0",
|
"version": "0.13.0",
|
||||||
"resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.13.0.tgz",
|
"resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.13.0.tgz",
|
||||||
|
@ -50,6 +50,7 @@
|
|||||||
"which": "5.0.0"
|
"which": "5.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@gradle/develocity-agent": "https://develocity-npm-pkgs.gradle.com/gradle-develocity-agent-0.9.0.tgz",
|
||||||
"@types/jest": "29.5.14",
|
"@types/jest": "29.5.14",
|
||||||
"@types/node": "20.17.14",
|
"@types/node": "20.17.14",
|
||||||
"@types/unzipper": "0.10.10",
|
"@types/unzipper": "0.10.10",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user