Skip to content

Commit fb15d59

Browse files
committed
feat: Use release drafter
1 parent 0f4d698 commit fb15d59

File tree

3 files changed

+143
-33
lines changed

3 files changed

+143
-33
lines changed

.github/release-drafter.yml

+118
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
---
2+
name-template: $RESOLVED_VERSION
3+
tag-template: $RESOLVED_VERSION
4+
include-pre-releases: true
5+
# prerelease-identifier: beta # Maybe?
6+
categories:
7+
- title: 💣 Breaking Changes
8+
labels:
9+
- breaking change
10+
- title: 🔔 Deprecation Warnings
11+
labels:
12+
- deprecation
13+
- title: 🚀 Features
14+
labels:
15+
- enhancement
16+
- title: 🐛 Bug Fixes
17+
labels:
18+
- bug
19+
- title: 🧪 Tests
20+
labels:
21+
- tests
22+
- title: 📝 Documentation
23+
labels:
24+
- documentation
25+
- title: 👷 CI/CD
26+
labels:
27+
- ci
28+
- build
29+
- title: 🔨 Maintenance
30+
labels:
31+
- chore
32+
- title: ⬆️ Dependencies
33+
collapse-after: 15
34+
labels:
35+
- dependencies
36+
- title: Other Changes
37+
labels:
38+
- *
39+
exclude-labels:
40+
- skip changelog
41+
version-resolver:
42+
minor:
43+
labels:
44+
- breaking change
45+
- deprecation
46+
patch:
47+
labels:
48+
- bug
49+
- chore
50+
- dependencies
51+
- documentation
52+
- enhancement
53+
- tests
54+
default: patch
55+
autolabeler:
56+
- label: breaking change
57+
body:
58+
- "/breaking/i"
59+
- label: deprecation
60+
branch:
61+
- "/deprecate\/.+/"
62+
title:
63+
- "/deprecate/i"
64+
- label: enhancement
65+
branch:
66+
- "/feat\/.+/"
67+
- "/feature\/.+/"
68+
title:
69+
- "/feat/i"
70+
- "/feature/i"
71+
- label: bug
72+
branch:
73+
- "/fix\/.+/"
74+
- "/bug\/.+/"
75+
- "/bugfix\/.+/"
76+
title:
77+
- "/fix/i"
78+
- "/bug/i"
79+
- "/bugfix/i"
80+
- label: tests
81+
branch:
82+
- "/tests{0,1}\/.+/"
83+
files:
84+
- "/tests/**"
85+
title:
86+
- "/tests{0,1}\/.+/i"
87+
- label: documentation
88+
branch:
89+
- "/docs{0,1}\/.+/"
90+
- "/documentation\/.+/"
91+
files:
92+
- "docs/**"
93+
title:
94+
- "/docs{0,1}\/.+/i"
95+
- "/documentation/i"
96+
- label: dependencies #todo review
97+
files:
98+
- ".github/workflows/requirements/*"
99+
replacers: #todo review
100+
- search: "/(feat|fix|docs|chore|cleanup|style|refactor|perf|test)(\(\w+\))?: /g"
101+
replace: ""
102+
template: |
103+
## What's new in the NGINX S3 Gateway v$RESOLVED_VERSION!
104+
105+
$CHANGES
106+
107+
## Install & Upgrade ## TODO Update or remove
108+
109+
- To install the Ansible NGINX role on a fresh environment, run `ansible-galaxy install nginxinc.nginx`.
110+
- To upgrade the Ansible NGINX role to the latest release, run `ansible-galaxy install -f nginxinc.nginx`.
111+
- To install or upgrade to this specific Ansible NGINX role release ($RESOLVED_VERSION), run `ansible-galaxy install -f nginxinc.nginx,v$RESOLVED_VERSION`.
112+
113+
## Resources ## TODO Update or remove
114+
115+
- Functional configuration examples (check `converge.yml` under each `molecule` scenario) -- [github.com/nginxinc/ansible-role-nginx/tree/$RESOLVED_VERSION/molecule](https://github.com/nginxinc/ansible-role-nginx/tree/$RESOLVED_VERSION/molecule).
116+
- Ansible Galaxy repository -- [galaxy.ansible.com/nginxinc/nginx](https://galaxy.ansible.com/nginxinc/nginx).
117+
- NGINX Ansible role & collection introductory blog -- [nginx.com/blog/announcing-nginx-core-collection-ansible](https://www.nginx.com/blog/announcing-nginx-core-collection-ansible).
118+
- NGINX: Better with Ansible demo -- [github.com/alessfg/nginx-ansible-demo](https://github.com/alessfg/nginx-ansible-demo).

.github/release.yml

-33
This file was deleted.

.github/workflows/release.yml

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
---
2+
name: Release Drafter
3+
on:
4+
push:
5+
branches: [main]
6+
# pull_request_target event is required for autolabeler to support PRs from forks
7+
pull_request_target:
8+
# Only following types are handled by the action, but one can default to all as well
9+
types: [opened, reopened, synchronize]
10+
11+
permissions: read-all
12+
jobs:
13+
update_release_draft:
14+
permissions:
15+
# write permission is required to create a github release
16+
contents: write
17+
# write permission is required for autolabeler
18+
# otherwise, read permission is required at least
19+
pull-requests: write
20+
runs-on: ubuntu-24.04
21+
steps:
22+
- name: Run Release Drafter
23+
uses: release-drafter/release-drafter@3f0f87098bd6b5c5b9a36d49c41d998ea58f9348 # v6.0.0
24+
env:
25+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)