Skip to content

Commit 36e315e

Browse files
committed
Add echo version & release action
1 parent 7b24a89 commit 36e315e

File tree

3 files changed

+55
-0
lines changed

3 files changed

+55
-0
lines changed

.github/release-drafter-config.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name-template: 'v$RESOLVED_VERSION 🌈'
2+
tag-template: 'v$RESOLVED_VERSION'
3+
categories:
4+
- title: '🚀 Features'
5+
labels:
6+
- 'feature'
7+
- 'enhancement'
8+
- title: '🐛 Bug Fixes'
9+
labels:
10+
- 'fix'
11+
- 'bugfix'
12+
- 'bug'
13+
- title: '🧰 Maintenance'
14+
label: 'chore'
15+
change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
16+
change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks.
17+
version-resolver:
18+
major:
19+
labels:
20+
- 'major'
21+
minor:
22+
labels:
23+
- 'minor'
24+
patch:
25+
labels:
26+
- 'patch'
27+
default: patch
28+
template: |
29+
## Changes
30+
31+
$CHANGES
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Release Drafter
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
tags:
8+
- 'v*'
9+
pull_request:
10+
types: [opened, reopened, labeled, synchronize]
11+
12+
jobs:
13+
update_release_draft:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: release-drafter/release-drafter@v5
17+
with:
18+
config-name: release-drafter-config.yml
19+
env:
20+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

gh-todo

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ Examples:
1818
EOF
1919
}
2020

21+
version="0.1.0"
2122
date=$(date -u +"%Y-%m-%d")
2223
repo="$(git config user.name)/todo"
2324

@@ -58,6 +59,9 @@ fi
5859

5960
while [ $# -gt 0 ]; do
6061
case "$1" in
62+
-v | --version)
63+
echo $version
64+
;;
6165
-h | --help)
6266
help
6367
exit 0

0 commit comments

Comments
 (0)