Skip to content

release PR refs/heads/main@06f54f303bc6f46e57edae0df05932fb26d55072 #5

release PR refs/heads/main@06f54f303bc6f46e57edae0df05932fb26d55072

release PR refs/heads/main@06f54f303bc6f46e57edae0df05932fb26d55072 #5

Workflow file for this run

name: release_pr
run-name: release PR ${{ github.ref }}@${{ github.sha }}
on:
workflow_dispatch:
inputs:
url:
description: Github repository URL to point links at, prefixed 'https://github.com/'
required: true
type: string
title:
description: Release title; new version and date will be added
type: string
tag_prefixes:
description: Comma separated prefixes to find tags, i.e $PREFIXv1.0.0
type: string
jobs:
release_pr:
name: release PR
runs-on: ubuntu-latest
steps:
- name: Validate branch
if: github.ref != 'refs/heads/main' && github.event.local != true
run: |
echo expected main, got: ${{ github.ref }} && exit 1
- name: Checkout
uses: actions/[email protected]
with:
fetch-tags: true
fetch-depth: 0
submodules: true
- name: Set up Go
uses: actions/[email protected]
with:
go-version: 1.23.1
# used in bump configs step
- run: go install github.com/mikefarah/yq/v4@latest
- name: Install changelog
if: github.event.local != true
run: go install github.com/tcodes0/go/cmd/t0changelog@latest
- name: Install changelog (local)
if: github.event.local == true
run: go install ./cmd/t0changelog
- name: Update changelog
shell: bash
env:
CHANGELOG_FILE: CHANGELOG.md
BASH_ENV: ./sh/lib/lib.sh
TAGS_FILE: tags.txt
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: ./sh/lib/workflows/release/changelog.sh "${{ inputs.url }}" "${{ inputs.title }}" "${{ inputs.tag_prefixes }}"
- name: Bump cmd configs version
shell: bash
env:
TAGS_FILE: tags.txt
run: ./sh/workflows/release/bump_cmd_configs.sh
- name: Open PR
uses: peter-evans/[email protected]
if: github.event.local != true
with:
commit-message: "chore: release ${{ inputs.title }}"
title: "chore: release ${{ inputs.title }}"
add-paths: .
body: ""
committer: release-workflow <41898282+github-actions[bot]@users.noreply.github.com>
branch: release-${{ inputs.title }}
branch-suffix: random