Class Release

  • All Implemented Interfaces:
    software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

    @Generated(value="jsii-pacmak/1.96.0 (build 921e240)",
               date="2024-03-28T21:16:43.257Z")
    @Stability(Experimental)
    public class Release
    extends Component
    (experimental) Manages releases (currently through GitHub workflows).

    By default, no branches are released. To add branches, call addBranch().

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  Release.Builder
      (experimental) A fluent builder for Release.
      • Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject

        software.amazon.jsii.JsiiObject.InitializationMode
      • Nested classes/interfaces inherited from interface software.constructs.IConstruct

        software.constructs.IConstruct.Jsii$Default, software.constructs.IConstruct.Jsii$Proxy
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected Release​(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)  
      protected Release​(software.amazon.jsii.JsiiObjectRef objRef)  
        Release​(software.constructs.IConstruct scope, ReleaseOptions options)  
    • Field Detail

      • ANTI_TAMPER_CMD

        @Stability(Experimental)
        public static final String ANTI_TAMPER_CMD
    • Constructor Detail

      • Release

        protected Release​(software.amazon.jsii.JsiiObjectRef objRef)
      • Release

        protected Release​(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
      • Release

        @Stability(Experimental)
        public Release​(@NotNull
                       software.constructs.IConstruct scope,
                       @NotNull
                       ReleaseOptions options)
        Parameters:
        scope - should be part of the project the Release belongs to. This parameter is required.
        options - options to configure the Release Component. This parameter is required.
    • Method Detail

      • of

        @Stability(Experimental)
        @Nullable
        public static Release of​(@NotNull
                                 Project project)
        (experimental) Returns the Release component of a project or undefined if the project does not have a Release component.

        Parameters:
        project - This parameter is required.
      • addBranch

        @Stability(Experimental)
        public void addBranch​(@NotNull
                              String branch,
                              @NotNull
                              BranchOptions options)
        (experimental) Adds a release branch.

        It is a git branch from which releases are published. If a project has more than one release branch, we require that majorVersion is also specified for the primary branch in order to ensure branches always release the correct version.

        Parameters:
        branch - The branch to monitor (e.g. main, v2.x). This parameter is required.
        options - Branch definition. This parameter is required.
      • addJobs

        @Stability(Experimental)
        public void addJobs​(@NotNull
                            Map<String,​Job> jobs)
        (experimental) Adds jobs to all release workflows.

        Parameters:
        jobs - The jobs to add (name => job). This parameter is required.
      • preSynthesize

        @Stability(Experimental)
        public void preSynthesize()
        (experimental) Called before synthesis.
        Overrides:
        preSynthesize in class Component
      • getArtifactsDirectory

        @Stability(Experimental)
        @NotNull
        public String getArtifactsDirectory()
        (experimental) Location of build artifacts.
      • getBranches

        @Stability(Experimental)
        @NotNull
        public List<String> getBranches()
        (experimental) Retrieve all release branch names.
      • getPublisher

        @Stability(Experimental)
        @NotNull
        public Publisher getPublisher()
        (experimental) Package publisher.