Skip to content
This repository has been archived by the owner on Mar 4, 2021. It is now read-only.

Documentation clarification on release event #115

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Documentation clarification on release event
Closes #71

The purpose of this PR is to make an important note about user expectations with regards to the `release` event created by this action. The crux of it is that the release event created by this action will not trigger another workflow.
  • Loading branch information
smac89 authored Jan 7, 2021
commit 6950523f4275c54c6dc3b39cdf1243483c21b968
16 changes: 15 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,24 @@ jobs:
prerelease: false
```

This will create a [Release](https://help.github.com/en/articles/creating-releases), as well as a [`release` event](https://developer.github.com/v3/activity/events/types/#releaseevent), which could be handled by a third party service, or by GitHub Actions for additional uses, for example the [`@actions/upload-release-asset`](https://www.github.com/actions/upload-release-asset) GitHub Action. This uses the `GITHUB_TOKEN` provided by the [virtual environment](https://help.github.com/en/github/automating-your-workflow-with-github-actions/virtual-environments-for-github-actions#github_token-secret), so no new token is needed.
This will create a [Release](https://help.github.com/en/articles/creating-releases), as well as a [`release` event](https://developer.github.com/v3/activity/events/types/#releaseevent) <sup>1</sup>, which could be handled by a third party service, or by GitHub Actions for additional uses, for example the [`@actions/upload-release-asset`](https://www.github.com/actions/upload-release-asset) GitHub Action.

## Contributing
We would love you to contribute to `@actions/create-release`, pull requests are welcome! Please see the [CONTRIBUTING.md](CONTRIBUTING.md) for more information.

## License
The scripts and documentation in this project are released under the [MIT License](LICENSE)

---
## Clarification on the Release event and Token usage

_Using the default `github.token` (or `secrets.GITHUB_TOKEN`), [will not trigger](https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#triggering-new-workflows-using-a-personal-access-token) another workflow, which depends on the [`release`](https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#release) event. i.e._

```yaml
on:
release:
types:
- published
...
```
_If you want to make use of another workflow which depends on the release event that may be triggered by using this action, you will have to supply a personal access token secret for the `GITHUB_TOKEN` environment variable. For more information on creating a Personal Access Token, see the [docs](https://docs.github.com/en/free-pro-team@latest/github/authenticating-to-github/creating-a-personal-access-token)._