get Release
Use this data source to retrieve information about a GitHub release in a specific repository.
Example Usage
To retrieve the latest release that is present in a repository:
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.github.GithubFunctions;
import com.pulumi.github.inputs.GetReleaseArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var example = GithubFunctions.getRelease(GetReleaseArgs.builder()
.owner("example-owner")
.repository("example-repository")
.retrieveBy("latest")
.build());
}
}
Content copied to clipboard
Return
A collection of values returned by getRelease.
Parameters
argument
A collection of arguments for invoking getRelease.
suspend fun getRelease(owner: String, releaseId: Int? = null, releaseTag: String? = null, repository: String, retrieveBy: String): GetReleaseResult
Return
A collection of values returned by getRelease.
Parameters
owner
Owner of the repository.
release Id
ID of the release to retrieve. Must be specified when retrieve_by
= id
.
release Tag
Tag of the release to retrieve. Must be specified when retrieve_by
= tag
.
repository
Name of the repository to retrieve the release from.
retrieve By
Describes how to fetch the release. Valid values are id
, tag
, latest
.
See also
Return
A collection of values returned by getRelease.
Parameters
argument
Builder for com.pulumi.github.kotlin.inputs.GetReleasePlainArgs.