GitHub deployment provider uploads build artifacts to an existing GitHub release or creates a new release if one does not already exist. You can publish artifacts during the build or use staged deployment by configuring new environment of
GitHub type at https://ci.appveyor.com/environments.
Note that the provider name
GitHub is case sensitive (e.g. not
Table of contents:
In this scenario, the GitHub deployment step is configured to run as part of the build process.
Alternatively, you may tell AppVeyor to create a “draft” release so you can perform any final checks before making it public.
In this scenario you configure a new “Environment” of GitHub type at https://ci.appveyor.com/environments, then:
To promote selected “tag” build to GitHub release:
tag) - Optional. If not specified build tag or version is used. You can use environment variables in tag name, for example
release) - Optional. The name of release. If not specified tag name is used as release name. You can use environment variables in release name, for example
product release of v$(appveyor_build_version).
description) - mandatory release description. If not specified, GitHub returns
422: Unprocessable entityerror.
auth_token) - OAuth token used for authentication against GitHub API. You can generate Personal API access token at https://github.com/settings/tokens. Minimal token scope is
public_repoto release on private or public repositories respectively. Be sure to encrypt your token using the Account → Encrypt data tool.
repository) - Optional. Allows to deploy into repository other than project’s one. Note that if this repository is under another owner, GitHub authentication token should be generated under that owner too. Use
artifact) - Optional. Allows specifying one or more build artifacts to be uploaded as release assets. The value could be comma-delimited list of artifact’s file name, deployment name or regular expression matching one of these. For example
/.*\.nupkg/. Don’t forget to package your artifact first, as the deployment will fail if this value does not match
artifacts.path(even if the file exists.)
trueif draft release should be created; default is
trueto mark release as “pre-release”; default is
trueto overwrite files in an existing release; default is
falsewhich will fail deployment if the release already exists on GitHub.
deploy: release: myproduct-v$(appveyor_build_version) description: 'Release description' provider: GitHub auth_token: secure: <your encrypted token> # your encrypted token from GitHub artifact: /.*\.nupkg/ # upload all NuGet packages to release assets draft: false prerelease: false on: branch: master # release from master branch only appveyor_repo_tag: true # deploy on tag push only