Skip to content

Commit

Permalink
[PR #1696/fe7057be backport][stable-5] Add a workflow (+actions) to a…
Browse files Browse the repository at this point in the history
…utomatically generate the GitHub Release when a valid tag is pushed (#1742)

[PR #1696/fe7057be backport][stable-5] Add a workflow (+actions) to automatically generate the GitHub Release when a valid tag is pushed

This is a backport of PR #1696 as merged into main (fe7057b).
SUMMARY
Automatically generate the GitHub release when we push a valid tag.  (Because we keep forgetting)
ISSUE TYPE
Feature Pull Request
COMPONENT NAME
.github/
ADDITIONAL INFORMATION
Reviewed-by: Mark Chappell

Reviewed-by: Alina Buzachis
  • Loading branch information
tremble committed Sep 7, 2023
1 parent d780ed4 commit b1eda07
Show file tree
Hide file tree
Showing 2 changed files with 67 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/release-manual.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Generate GitHub Release (manual trigger)
concurrency:
group: release-${{ github.head_ref }}
cancel-in-progress: true
on:
workflow_dispatch:
inputs:
release:
required: true
description: 'Release to generate'
type: string

jobs:
generate-release-log:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- name: Generate Release Log
uses: ansible-collections/amazon.aws/.github/actions/ansible_release_log@main
with:
release: ${{ inputs.release }}

perform-release:
permissions:
contents: write
runs-on: ubuntu-latest
needs:
- generate-release-log
steps:
- name: Generate Release
uses: ansible-collections/amazon.aws/.github/actions/ansible_release_tag@main
with:
release: ${{ inputs.release }}
collection-name: amazon.aws
32 changes: 32 additions & 0 deletions .github/workflows/release-tag.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Generate GitHub Release
concurrency:
group: release-${{ github.head_ref }}
cancel-in-progress: true
on:
push:
tags:
- '*'

jobs:
generate-release-log:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- name: Generate Release Log
uses: ansible-collections/amazon.aws/.github/actions/ansible_release_log@main
with:
release: ${{ github.ref_name }}

perform-release:
permissions:
contents: write
runs-on: ubuntu-latest
needs:
- generate-release-log
steps:
- name: Generate Release
uses: ansible-collections/amazon.aws/.github/actions/ansible_release_tag@main
with:
release: ${{ github.ref_name }}
collection-name: amazon.aws

0 comments on commit b1eda07

Please sign in to comment.