Repository navigation
48 lines (47 loc) · 1.63 KB
/
Copy pathrelease.yaml
File metadata and controls
48 lines (47 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Copyright 2026 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Pushing a vX.Y.Z[-PRERELEASE] tag creates a DRAFT release with generated
# notes (.github/release.yml). A maintainer edits and publishes it; see
# docs/dev/release-notes.md. Run manually to draft a release for a tag that
# has none; an existing release is never modified.
name: release
on:
push:
tags: ['v*']
workflow_dispatch:
inputs:
tag:
description: 'Existing tag to draft a release for (e.g. v0.3.0)'
required: true
# Creating a release needs contents: write.
permissions:
contents: write
concurrency:
group: release-${{ inputs.tag || github.ref_name }}
jobs:
draft:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5.1.0
with:
# The committer list is read from local history back to the
# previous release tag.
fetch-depth: 0
persist-credentials: false
- name: Draft release
env:
GH_TOKEN: ${{ github.token }}
TAG: ${{ inputs.tag || github.ref_name }}
run: hack/release/draft-release.sh "${TAG}"