Soenneker.GitHub.Repositories.Releases
4.0.1016
Prefix Reserved
dotnet add package Soenneker.GitHub.Repositories.Releases --version 4.0.1016
NuGet\Install-Package Soenneker.GitHub.Repositories.Releases -Version 4.0.1016
<PackageReference Include="Soenneker.GitHub.Repositories.Releases" Version="4.0.1016" />
<PackageVersion Include="Soenneker.GitHub.Repositories.Releases" Version="4.0.1016" />
<PackageReference Include="Soenneker.GitHub.Repositories.Releases" />
paket add Soenneker.GitHub.Repositories.Releases --version 4.0.1016
#r "nuget: Soenneker.GitHub.Repositories.Releases, 4.0.1016"
#:package Soenneker.GitHub.Repositories.Releases@4.0.1016
#addin nuget:?package=Soenneker.GitHub.Repositories.Releases&version=4.0.1016
#tool nuget:?package=Soenneker.GitHub.Repositories.Releases&version=4.0.1016
Soenneker.GitHub.Repositories.Releases
Create and delete GitHub releases, upload release assets, and download assets from the latest published release.
Installation
dotnet add package Soenneker.GitHub.Repositories.Releases
Configuration
{
"GH": {
"Token": "github-token"
}
}
The token needs repository contents write access to create tags and releases. It must also be able to read any private release assets being downloaded.
Registration
services.AddGitHubRepositoriesReleasesUtilAsSingleton();
Use AddGitHubRepositoriesReleasesUtilAsScoped() for a scoped consumer.
Create a release with an asset
await releases.Create(
owner: "soenneker",
repo: "example-repository",
tagName: "v1.2.0",
releaseName: "v1.2.0",
releaseBody: "Release notes",
filePath: @"C:\artifacts\example.zip",
cancellationToken: cancellationToken);
Create reuses an existing tag or creates one when missing, creates the release, and uploads the specified file as one release asset. isDraft and isPrerelease control the GitHub release flags.
Download release assets
List<string> paths = await releases.DownloadAllLatestReleaseAssets(
"soenneker",
"example-repository",
@"C:\downloads",
cancellationToken);
string? windowsAsset = await releases.DownloadReleaseAssetByNamePattern(
"soenneker",
"example-repository",
@"C:\downloads",
["win", "x64"],
cancellationToken);
The latest release is the newest non-draft release by creation time. Name-pattern matching is case-insensitive and requires every supplied fragment to appear in the asset name. Existing local files with the same name are replaced.
Deletion
Delete removes the release for a tag and deletes that Git tag by default. Pass deleteTag: false to preserve it. DeleteAllForRepository applies the same behavior to every release in the repository and is irreversible through this library.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Soenneker.GitHub.Repositories.Tags (>= 4.0.980)
- Soenneker.Utils.File (>= 4.0.2260)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on Soenneker.GitHub.Repositories.Releases:
| Package | Downloads |
|---|---|
|
Soenneker.GitHub.Repositories.Suite
Registers commonly used Soenneker GitHub repository services through one package |
|
|
Soenneker.Managers.Runners
Handles Runner operations and coordination |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.1016 | 0 | 9/9/2026 |
| 4.0.1015 | 0 | 9/9/2026 |
| 4.0.1014 | 0 | 9/8/2026 |
| 4.0.1013 | 0 | 9/8/2026 |
| 4.0.1012 | 0 | 9/8/2026 |
| 4.0.1011 | 0 | 9/8/2026 |
| 4.0.1010 | 0 | 9/8/2026 |
| 4.0.1009 | 0 | 9/8/2026 |
| 4.0.1008 | 31 | 9/8/2026 |
| 4.0.1007 | 49 | 9/8/2026 |
| 4.0.1006 | 487 | 9/8/2026 |
| 4.0.1005 | 885 | 9/7/2026 |
| 4.0.1004 | 306 | 9/7/2026 |
| 4.0.1003 | 533 | 9/7/2026 |
| 4.0.1002 | 765 | 9/7/2026 |
| 4.0.1001 | 50 | 9/7/2026 |
| 4.0.1000 | 3,162 | 9/5/2026 |
| 4.0.999 | 60 | 9/5/2026 |
| 4.0.998 | 770 | 9/5/2026 |
| 4.0.997 | 195 | 9/5/2026 |
Update dependency Soenneker.Utils.File to 4.0.2260 (#1735)