Package io.github.cdklabs.projen.github
Class UploadArtifactWith.Builder
- java.lang.Object
-
- io.github.cdklabs.projen.github.UploadArtifactWith.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<UploadArtifactWith>
- Enclosing interface:
- UploadArtifactWith
@Stability(Experimental) public static final class UploadArtifactWith.Builder extends Object implements software.amazon.jsii.Builder<UploadArtifactWith>
A builder forUploadArtifactWith
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UploadArtifactWithbuild()Builds the configured instance.UploadArtifactWith.BuildercompressionLevel(Number compressionLevel)Sets the value ofUploadArtifactWith.getCompressionLevel()UploadArtifactWith.BuilderifNoFilesFound(String ifNoFilesFound)Sets the value ofUploadArtifactWith.getIfNoFilesFound()UploadArtifactWith.Buildername(String name)Sets the value ofUploadArtifactWith.getName()UploadArtifactWith.Builderoverwrite(Boolean overwrite)Sets the value ofUploadArtifactWith.getOverwrite()UploadArtifactWith.Builderpath(String path)Sets the value ofUploadArtifactWith.getPath()UploadArtifactWith.BuilderretentionDays(Number retentionDays)Sets the value ofUploadArtifactWith.getRetentionDays()
-
-
-
Method Detail
-
path
@Stability(Experimental) public UploadArtifactWith.Builder path(String path)
Sets the value ofUploadArtifactWith.getPath()- Parameters:
path- A file, directory or wildcard pattern that describes what to upload. This parameter is required.- Returns:
this
-
compressionLevel
@Stability(Experimental) public UploadArtifactWith.Builder compressionLevel(Number compressionLevel)
Sets the value ofUploadArtifactWith.getCompressionLevel()- Parameters:
compressionLevel- The level of compression for Zlib to be applied to the artifact archive. The value can range from 0 to 9. For large files that are not easily compressed, a value of 0 is recommended for significantly faster uploads.- Returns:
this
-
ifNoFilesFound
@Stability(Experimental) public UploadArtifactWith.Builder ifNoFilesFound(String ifNoFilesFound)
Sets the value ofUploadArtifactWith.getIfNoFilesFound()- Parameters:
ifNoFilesFound- The desired behavior if no files are found using the provided path. Available Options: warn: Output a warning but do not fail the action error: Fail the action with an error message ignore: Do not output any warnings or errors, the action does not fail- Returns:
this
-
name
@Stability(Experimental) public UploadArtifactWith.Builder name(String name)
Sets the value ofUploadArtifactWith.getName()- Parameters:
name- Name of the artifact to upload.- Returns:
this
-
overwrite
@Stability(Experimental) public UploadArtifactWith.Builder overwrite(Boolean overwrite)
Sets the value ofUploadArtifactWith.getOverwrite()- Parameters:
overwrite- Whether action should overwrite an existing artifact with the same name (should one exist). Introduced in v4 and represents a breaking change from the behavior of the v3 action. To maintain backwards compatibility with existing, this should be set thetrue(the default).- Returns:
this
-
retentionDays
@Stability(Experimental) public UploadArtifactWith.Builder retentionDays(Number retentionDays)
Sets the value ofUploadArtifactWith.getRetentionDays()- Parameters:
retentionDays- Duration after which artifact will expire in days. 0 means using default repository retention. Minimum 1 day. Maximum 90 days unless changed from the repository settings page.- Returns:
this
-
build
@Stability(Experimental) public UploadArtifactWith build()
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<UploadArtifactWith>- Returns:
- a new instance of
UploadArtifactWith - Throws:
NullPointerException- if any required attribute was not provided
-
-