This template helps developers get started with publishing the C# SDK to NuGet Gellery package repository.
The user will need the following:
- A NuGet Gallery account with an NuGet API key that allows uploading packages into the desired project
This repository contains the following:
- A
README
that contains the instructions - A GitHub Actions workflow to publish the C# SDK to NuGet Gallery package repository.
-
Create a new target C# SDK Repo by clicking the Use this template button at the top of this repository.
-
Set the
NUGET_TOKEN
actions secret in the target SDK repo. -
If you already have a Control Repo:
-
Update your
LIBLAB_GITHUB_TOKEN
actions secret to a new token that has access to all your existing SDK repos, as well as this new one. -
Update the
githubRepoName
field in thecsharp
section of your liblab config file to the name of your new repo.
-
-
Run the GitHub Action
Generate SDKs using liblab
in the Control Repo that builds the SDK, and raises a PR against this target SDK Repo. This will be triggered automatically when you commit and push the update to the liblab config file. -
Review and merge the PR.
-
Create a release in the target SDK Repo.
-
The GitHub Action
Publish to NuGet Gallery package repository
in the target SDK Repo will be triggered by the release, and publish the package to NuGet.