Skip to content

nekofar/create-github-release

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Create GitHub Release Action

GitHub release (latest SemVer including pre-releases) GitHub Workflow Status (branch) GitHub Twitter Follow Donate

GitHub Action to create a new release with optional notes and files.

Usage

# This workflow is named "Create Release"
name: Create Release

# The workflow is triggered on push events with tags that start with 'v'
on:
  push:
    tags:
      - 'v*'

jobs:
  create_release:
    # Runs the job on the latest Ubuntu version
    runs-on: ubuntu-latest

    steps:
      # Checks out a copy of your repository
      - name: Checkout code
        uses: actions/checkout@v2

      - name: Create Release
        # Uses the create-github-release action
        uses: nekofar/create-github-release@v1
        with:
          # Defines the tag name for the release (e.g., v1.0.0).
          tag: ${{ github.ref_name }}

          # (Optional) Files to include in the release
          files: |
            dist/release-assets/*  

          # (Optional) Defines the title of the release
          title: Release ${{ github.ref_name }}

          # (Optional) Allows multiline release notes
          notes: |
            This is the release notes for version ${{ github.ref_name }}.
            Add any important information here.

          # (Optional) Set to "true" to create a draft release. Default is "false"
          draft: false

          # (Optional) Set to "true" to create a pre-release. Default is "false"
          prerelease: false

          # (Optional) Set to "true" to mark this release as the latest. Default is "false"
          latest: true

          # (Optional) GitHub token for authentication. Default: ${{ github.token }}. If not provided, it will use the repository's default token
          token: ${{ github.token }}          

Options

The configuration used in the GitHub Action workflow includes several options for customization. Each of these configuration options has a specific use and can be tailored to suit your specific workflow needs. Below is a table depicting these options:

Option Description
tag This defines the tag name for the release (e.g., v1.0.0).
files (Optional) This specifies any files that you wish to include in the release.
title (Optional) This defines the title of the release.
notes (Optional) This allows multiline release notes.
draft (Optional) This can be set to "true" to create a draft release. The default is "false".
prerelease (Optional) This can be set to "true" to create a pre-release. The default is "false".
latest (Optional) This can be set to "true" to mark this release as the latest. The default is "false".
token (Optional) This is the GitHub token for authentication. The default is github.token. If not provided, it will use the repository's default token.

Each option should be carefully considered to ensure that your workflow proceeds as expected.

Contributing

We value your input and help! If you're interested in contributing, please reference our Contributing Guidelines. Contributions aren't just about code - any bug reports, feedback, or documentation enhancements are welcomed. Thanks for helping to improve this project!