Demo project to demonstrate automatically publishing a NuGet package for a PowerShell project.
For more information, read this
I extended the pipeline by adding automatic versioning using MinVer.
- Create Azure DevOps organization and project.
- Install Pester Azure DevOps extension.
- Create the pipeline by clicking New Pipeline. Choose GitHub for Where is your code?. Select the repository and path for
azure-pipelines.yml
- You can configure Azure Pipelines to build GitHub pull requests only when authorized by your team. To enable this, in Azure Pipelines, select the Triggers tab in your pipeline's settings. Then, under Pull request validation, Comments enable Require a team member's comment before building a pull request and save the pipeline. Now, the pull request validation build will not be triggered automatically.
- Ensure Artifacts are Enabled for the project.
- Add
[ProjectName] Build Service ([org name])
as contributor to pre-created NuGet feed.
If you want to display a build status badge, make sure your Azure DevOps project is public and follow these instructions.