mirror of
https://github.com/gradle/actions.git
synced 2026-08-29 19:28:23 +08:00
Consolidates seven open bot PRs into three commits. ## 1. Bump Gradle Wrapper from 9.5.1 to 9.6.1 Combines **#1008, #1009, #1010, #1011, #1012** into a single commit. Each of those PRs bumped the wrapper in one directory; this covers all five (15 files): - `sources/test/init-scripts` - `.github/workflow-samples/gradle-plugin` - `.github/workflow-samples/groovy-dsl` - `.github/workflow-samples/java-toolchain` - `.github/workflow-samples/kotlin-dsl` Each location gets the same `distributionUrl` → `gradle-9.6.1-bin.zip` and `distributionSha256Sum` update, plus the regenerated `gradlew` / `gradlew.bat` scripts. ## 2. Update known wrapper checksums **#990**, unchanged, as its own commit. Adds 36 checksum entries to `sources/src/wrapper-validation/wrapper-checksums.json`, **including the 9.6.1 checksums** — which is what lets the wrapper bump above pass `CI-validate-wrappers`. These two are worth landing together. ## 3. Bump Develocity Gradle plugin from 4.4.2 to 4.5.0 **#1015**, unchanged, as its own commit. Updates the plugin reference across workflow samples, init-script tests, docs, and the injected default in `sources/src/develocity/build-scan.ts`: ```diff -maybeExportVariable('DEVELOCITY_INJECTION_DEVELOCITY_PLUGIN_VERSION', '4.4.2') +maybeExportVariable('DEVELOCITY_INJECTION_DEVELOCITY_PLUGIN_VERSION', '4.5.0') ``` Since this touches `sources/src`, the bundled `dist/` will change when the update-dist bot runs. ## Verification All three cherry-picks applied without conflicts. On the combined branch: - `./build` — clean - `npm run check` (prettier + eslint) — clean - `npm test` — 373 tests, 15 suites, all passing Original bot authorship is preserved on all three commits. ## Superseded PRs Once this merges, these can be closed: #1008, #1009, #1010, #1011, #1012, #990, #1015. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> Co-authored-by: bot-githubaction <bot-githubaction@gradle.com>
54 lines
2.6 KiB
TypeScript
54 lines
2.6 KiB
TypeScript
import * as core from '@actions/core'
|
|
import {DevelocityConfig} from '../configuration'
|
|
|
|
export function setup(config: DevelocityConfig): void {
|
|
maybeExportVariable('DEVELOCITY_INJECTION_INIT_SCRIPT_NAME', 'gradle-actions.inject-develocity.init.gradle')
|
|
maybeExportVariable('DEVELOCITY_INJECTION_CUSTOM_VALUE', 'gradle-actions')
|
|
|
|
maybeExportVariableNotEmpty('DEVELOCITY_INJECTION_ENABLED', config.getDevelocityInjectionEnabled())
|
|
maybeExportVariableNotEmpty('DEVELOCITY_INJECTION_URL', config.getDevelocityUrl())
|
|
maybeExportVariableNotEmpty(
|
|
'DEVELOCITY_INJECTION_ALLOW_UNTRUSTED_SERVER',
|
|
config.getDevelocityAllowUntrustedServer()
|
|
)
|
|
maybeExportVariableNotEmpty(
|
|
'DEVELOCITY_INJECTION_CAPTURE_FILE_FINGERPRINTS',
|
|
config.getDevelocityCaptureFileFingerprints()
|
|
)
|
|
maybeExportVariableNotEmpty('DEVELOCITY_INJECTION_ENFORCE_URL', config.getDevelocityEnforceUrl())
|
|
maybeExportVariableNotEmpty('DEVELOCITY_INJECTION_DEVELOCITY_PLUGIN_VERSION', config.getDevelocityPluginVersion())
|
|
maybeExportVariableNotEmpty('DEVELOCITY_INJECTION_CCUD_PLUGIN_VERSION', config.getDevelocityCcudPluginVersion())
|
|
maybeExportVariableNotEmpty('DEVELOCITY_INJECTION_PLUGIN_REPOSITORY_URL', config.getPluginRepository().getUrl())
|
|
maybeExportVariableNotEmpty(
|
|
'DEVELOCITY_INJECTION_PLUGIN_REPOSITORY_USERNAME',
|
|
config.getPluginRepository().getUsername()
|
|
)
|
|
maybeExportVariableNotEmpty(
|
|
'DEVELOCITY_INJECTION_PLUGIN_REPOSITORY_PASSWORD',
|
|
config.getPluginRepository().getPassword()
|
|
)
|
|
|
|
// If build-scan-publish is enabled, ensure the environment variables are set
|
|
// The DEVELOCITY_PLUGIN_VERSION and DEVELOCITY_CCUD_PLUGIN_VERSION are set to the latest versions
|
|
// except if they are defined in the configuration
|
|
if (config.getBuildScanPublishEnabled()) {
|
|
maybeExportVariable('DEVELOCITY_INJECTION_ENABLED', 'true')
|
|
maybeExportVariable('DEVELOCITY_INJECTION_DEVELOCITY_PLUGIN_VERSION', '4.5.0')
|
|
maybeExportVariable('DEVELOCITY_INJECTION_CCUD_PLUGIN_VERSION', '2.1')
|
|
maybeExportVariable('DEVELOCITY_INJECTION_TERMS_OF_USE_URL', config.getTermsOfUseUrl())
|
|
maybeExportVariable('DEVELOCITY_INJECTION_TERMS_OF_USE_AGREE', config.getTermsOfUseAgree())
|
|
}
|
|
}
|
|
|
|
function maybeExportVariable(variableName: string, value: unknown): void {
|
|
if (!process.env[variableName]) {
|
|
core.exportVariable(variableName, value)
|
|
}
|
|
}
|
|
|
|
function maybeExportVariableNotEmpty(variableName: string, value: unknown): void {
|
|
if (value !== null && value !== undefined && value !== '') {
|
|
maybeExportVariable(variableName, value)
|
|
}
|
|
}
|