2024-01-16 01:42:57 +00:00
name : Gradle Dependency Submission
description : Generates a dependency graph for a Gradle project and submits it via the Dependency Submission API
inputs :
2024-04-09 14:46:20 +00:00
# Gradle execution configuration
2024-01-16 01:42:57 +00:00
gradle-version :
description : |
Gradle version to use. If specified, this Gradle version will be downloaded, added to the PATH and used for invoking Gradle.
If not provided, it is assumed that the project uses the Gradle Wrapper.
required : false
2024-04-07 18:11:50 +00:00
2024-01-16 01:42:57 +00:00
build-root-directory :
description : Path to the root directory of the build. Default is the root of the GitHub workspace.
required : false
2024-04-07 18:11:50 +00:00
2024-04-09 14:46:20 +00:00
dependency-resolution-task :
description : |
2024-05-15 22:49:55 +00:00
Task(s) that should be executed in order to resolve all project dependencies.
2024-04-09 14:46:20 +00:00
By default, the built-in `:ForceDependencyResolutionPlugin_resolveAllDependencies` task is executed.
required : false
2024-04-07 18:11:50 +00:00
additional-arguments :
description : |
2024-05-15 22:49:55 +00:00
Additional arguments to pass to Gradle when generating the dependency graph.
2024-04-07 18:11:50 +00:00
For example, `--no-configuration-cache --stacktrace`.
required : false
# Cache configuration
cache-disabled :
description : When 'true', all caching is disabled. No entries will be written to or read from the cache.
required : false
default : false
cache-read-only :
description : |
When 'true', existing entries will be read from the cache but no entries will be written.
By default this value is 'false' for workflows on the GitHub default branch and 'true' for workflows on other branches.
required : false
default : ${{ github.event.repository != null && github.ref_name != github.event.repository.default_branch }}
cache-write-only :
description : |
2024-05-15 22:49:55 +00:00
When 'true', entries will not be restored from the cache but will be saved at the end of the Job.
2024-04-07 18:11:50 +00:00
Setting this to 'true' implies cache-read-only will be 'false'.
required : false
default : false
cache-overwrite-existing :
description : When 'true', a pre-existing Gradle User Home will not prevent the cache from being restored.
required : false
default : false
2024-01-16 01:42:57 +00:00
cache-encryption-key :
description : |
2024-05-15 22:49:55 +00:00
A base64 encoded AES key used to encrypt the configuration-cache data. The key is exported as 'GRADLE_ENCRYPTION_KEY' for later steps.
2024-01-16 01:42:57 +00:00
A suitable key can be generated with `openssl rand -base64 16`.
Configuration-cache data will not be saved/restored without an encryption key being provided.
required : false
2024-04-07 18:11:50 +00:00
2024-07-18 01:02:31 +00:00
cache-cleanup :
description : |
Specifies if the action should attempt to remove any stale/unused entries from the Gradle User Home prior to saving to the GitHub Actions cache.
2024-08-05 16:54:56 +00:00
By default ('on-success'), cleanup is performed when all Gradle builds succeed for the Job.
This behaviour can be disabled ('never'), or configured to always run irrespective of the build outcome ('always').
2024-07-18 01:02:31 +00:00
Valid values are 'never', 'on-success' and 'always'.
required : false
2024-07-21 19:44:32 +00:00
default : 'on-success'
2024-07-18 01:02:31 +00:00
gradle-home-cache-cleanup :
description : When 'true', the action will attempt to remove any stale/unused entries from the Gradle User Home prior to saving to the GitHub Actions cache.
required : false
deprecation-message : This input has been superceded by the 'cache-cleanup' input parameter.
2024-04-07 18:11:50 +00:00
gradle-home-cache-includes :
description : Paths within Gradle User Home to cache.
required : false
default : |
caches
notifications
gradle-home-cache-excludes :
description : Paths within Gradle User Home to exclude from cache.
required : false
# Job summary configuration
add-job-summary :
description : Specifies when a Job Summary should be inluded in the action results. Valid values are 'never', 'always' (default), and 'on-failure'.
required : false
default : 'always'
add-job-summary-as-pr-comment :
description : Specifies when each Job Summary should be added as a PR comment. Valid values are 'never' (default), 'always', and 'on-failure'. No action will be taken if the workflow was not triggered from a pull request.
required : false
default : 'never'
# Dependency Graph configuration
2024-01-29 16:48:54 +00:00
dependency-graph :
2024-01-22 17:57:20 +00:00
description : |
Specifies how the dependency-graph should be handled by this action. By default a dependency-graph will be generated and submitted.
Valid values are :
'generate-and-submit' (default) : Generates a dependency graph for the project and submits it in the same Job.
2024-01-29 16:48:54 +00:00
'generate-and-upload' : Generates a dependency graph for the project and saves it as a workflow artifact.
'download-and-submit' : Retrieves a previously saved dependency-graph and submits it to the repository.
2024-05-15 22:49:55 +00:00
2024-01-22 17:57:20 +00:00
The `generate-and-upload` and `download-and-submit` options are designed to be used in an untrusted workflow scenario,
where the workflow generating the dependency-graph cannot (or should not) be given the `contents : write` permissions
required to submit via the Dependency Submission API.
required : false
default : 'generate-and-submit'
2024-04-07 18:11:50 +00:00
2024-07-19 22:20:52 +00:00
dependency-graph-report-dir :
description : |
Specifies where the dependency graph report will be generated.
Paths can relative or absolute. Relative paths are resolved relative to the workspace directory.
required : false
default : 'dependency-graph-reports'
2024-04-07 18:11:50 +00:00
dependency-graph-continue-on-failure :
description : When 'false' a failure to generate or submit a dependency graph will fail the Step or Job. When 'true' a warning will be emitted but no failure will result.
2024-01-28 18:34:50 +00:00
required : false
2024-04-07 18:11:50 +00:00
default : false
2024-01-16 01:42:57 +00:00
2024-07-19 23:07:41 +00:00
dependency-graph-exclude-projects :
description : |
Gradle projects that should be excluded from dependency graph (regular expression).
When set, any matching project will be excluded.
required : false
dependency-graph-include-projects :
description : |
Gradle projects that should be included in dependency graph (regular expression).
When set, only matching projects will be included.
required : false
dependency-graph-exclude-configurations :
description : |
Gradle configurations that should be included in dependency graph (regular expression).
When set, anymatching configurations will be excluded.
required : false
dependency-graph-include-configurations :
description : |
Gradle configurations that should be included in dependency graph (regular expression).
When set, only matching configurations will be included.
required : false
2024-04-07 18:11:50 +00:00
artifact-retention-days :
description : Specifies the number of days to retain any artifacts generated by the action. If not set, the default retention settings for the repository will apply.
required : false
default : 1
# Build Scan configuration
2024-01-28 17:02:24 +00:00
build-scan-publish :
description : |
Set to 'true' to automatically publish build results as a Build Scan on scans.gradle.com.
2024-04-03 20:47:50 +00:00
For publication to succeed without user input, you must also provide values for `build-scan-terms-of-use-url` and 'build-scan-terms-of-use-agree'.
2024-01-28 17:02:24 +00:00
required : false
default : false
2024-04-07 18:11:50 +00:00
2024-04-03 20:47:50 +00:00
build-scan-terms-of-use-url :
2024-04-07 18:11:50 +00:00
description : The URL to the Build Scan® terms of use. This input must be set to 'https://gradle.com/terms-of-service' or 'https://gradle.com/help/legal-terms-of-use'.
2024-01-28 17:02:24 +00:00
required : false
2024-05-15 22:49:55 +00:00
2024-04-03 20:47:50 +00:00
build-scan-terms-of-use-agree :
description : Indicate that you agree to the Build Scan® terms of use. This input value must be "yes".
2024-01-28 17:02:24 +00:00
required : false
2024-05-15 22:49:55 +00:00
develocity-access-key :
description : Develocity access key. Should be set to a secret containing the Develocity Access key.
required : false
develocity-token-expiry :
description : The Develocity short-lived access tokens expiry in hours. Default is 2 hours.
required : false
2024-08-01 02:38:10 +00:00
# Wrapper validation configuration
validate-wrappers :
description : |
When 'true' the action will automatically validate all wrapper jars found in the repository.
If the wrapper checksums are not valid, the action will fail.
required : false
default : false
allow-snapshot-wrappers :
description : |
When 'true', wrapper validation will include the checksums of snapshot wrapper jars.
Use this if you are running with nightly or snapshot versions of the Gradle wrapper.
required : false
default : false
2024-04-07 18:11:50 +00:00
# DEPRECATED ACTION INPUTS
# EXPERIMENTAL ACTION INPUTS
# The following action properties allow fine-grained tweaking of the action caching behaviour.
# These properties are experimental and not (yet) designed for production use, and may change without notice in a subsequent release of `setup-gradle`.
# Use at your own risk!
gradle-home-cache-strict-match :
description : When 'true', the action will not attempt to restore the Gradle User Home entries from other Jobs.
2024-04-07 17:54:02 +00:00
required : false
2024-04-07 18:11:50 +00:00
default : false
2024-05-15 22:49:55 +00:00
2024-04-07 18:11:50 +00:00
# INTERNAL ACTION INPUTS
# These inputs should not be configured directly, and are only used to pass environmental information to the action
2024-04-07 17:54:02 +00:00
workflow-job-context :
2024-04-07 18:11:50 +00:00
description : Used to uniquely identify the current job invocation. Defaults to the matrix values for this job; this should not be overridden by users (INTERNAL).
2024-04-07 17:54:02 +00:00
required : false
default : ${{ toJSON(matrix) }}
2024-04-07 18:11:50 +00:00
2024-04-07 17:54:02 +00:00
github-token :
2024-04-07 18:11:50 +00:00
description : The GitHub token used to authenticate when submitting via the Dependency Submission API.
2024-04-07 17:54:02 +00:00
default : ${{ github.token }}
required : false
2024-04-04 19:19:48 +00:00
2024-04-07 18:11:50 +00:00
outputs :
build-scan-url :
description : Link to the Build Scan® generated by a Gradle build. Note that this output applies to a Step executing Gradle, not to the `setup-gradle` Step itself.
dependency-graph-file :
description : Path to the GitHub Dependency Graph snapshot file generated by a Gradle build. Note that this output applies to a Step executing Gradle, not to the `setup-gradle` Step itself.
gradle-version :
description : Version of Gradle that was setup by the action
2024-04-04 19:19:48 +00:00
2024-01-16 01:42:57 +00:00
runs :
2024-04-06 22:35:03 +00:00
using : 'node20'
main : '../dist/dependency-submission/main/index.js'
post : '../dist/dependency-submission/post/index.js'
2024-04-07 18:11:50 +00:00
branding :
icon : 'box'
color : 'gray-dark'