2019-08-25 06:14:36 +00:00
|
|
|
# action gh-release [![](https://github.com/softprops/action-gh-release/workflows/Main/badge.svg)](https://github.com/softprops/action-gh-release/actions)
|
|
|
|
|
2019-08-25 06:13:05 +00:00
|
|
|
|
2019-08-26 04:40:00 +00:00
|
|
|
A GitHub Action for creating GitHub Releases
|
2019-08-25 06:17:36 +00:00
|
|
|
|
2019-08-25 19:24:49 +00:00
|
|
|
## Usage
|
|
|
|
|
|
|
|
```yaml
|
|
|
|
name: Main
|
|
|
|
|
|
|
|
on: push
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@master
|
|
|
|
- name: Build
|
|
|
|
run: echo ${{ github.sha }} > Release.txt
|
|
|
|
- name: Release
|
|
|
|
uses: docker://softprops/action-gh-release
|
2019-08-25 22:37:27 +00:00
|
|
|
if: startsWith(github.ref, 'refs/tags/')
|
2019-08-25 19:25:36 +00:00
|
|
|
with:
|
|
|
|
files: Release.txt
|
2019-08-25 19:24:49 +00:00
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
```
|
|
|
|
|
2019-08-26 02:32:14 +00:00
|
|
|
## inputs
|
|
|
|
|
|
|
|
| Name | Type | Description |
|
|
|
|
|---------|---------|---------------------------------------------------------------|
|
2019-08-26 04:40:00 +00:00
|
|
|
| `body` | String | Text communicating notable changes in this release |
|
|
|
|
| `draft` | Boolean | Indicator of whether or not this release is a draft |
|
|
|
|
| `files` | String | Comma-delimited globs of paths to assets to upload for release|
|
|
|
|
| `name` | String | Name of the release. defaults to tag name |
|
2019-08-26 02:32:14 +00:00
|
|
|
|
|
|
|
## environment variables
|
|
|
|
|
|
|
|
| Name | Description |
|
|
|
|
|----------------|--------------------------------------|
|
|
|
|
| `GITHUB_TOKEN` | GITHUB_TOKEN as provided by `secrets`|
|
|
|
|
|
2019-08-25 06:17:36 +00:00
|
|
|
Doug Tangren (softprops) 2019
|