You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# This script uses github_changelog_generator to generate a changelog and requires:
5
+
#
6
+
# 1. set an env GITHUB_TOKEN for the Github token
7
+
# 2. previous release as an arg, to generate changelog since the mentioned release
8
+
# 3. github_changelog_generator be installed where the script is being executed
9
+
#
10
+
# A CHANGELOG.md is generated and it's contents can be copy-pasted on the Github release
11
+
12
+
#TODO: Since issue tracking happens in devfile/api, github_changelog_generator cannot
13
+
# detect the issues from a different repository. Need to check if this is achievable.
14
+
15
+
BLUE='\033[1;34m'
16
+
GREEN='\033[0;32m'
17
+
RED='\033[0;31m'
18
+
NC='\033[0m'
19
+
BOLD='\033[1m'
20
+
21
+
# Ensure the github token is set
22
+
if [ -z"$GITHUB_TOKEN" ]
23
+
then
24
+
echo -e "${RED}GITHUB_TOKEN env variable is empty..\nGet your GitHub token from https://github.com/settings/tokens and export GITHUB_TOKEN=<token>${NC}"
25
+
exit 1
26
+
fi
27
+
28
+
# Ensure there is a release version passed in
29
+
if [ -z"$1" ]
30
+
then
31
+
echo -e "${RED}The last release version needs to be provided. Changelog will be generated since that release..${NC}"
32
+
echo -e "${RED}Example: ./changelog-script.sh v1.0.0-alpha.2 will generate a changelog for all the changes since release v1.0.0-alpha.2${NC}"
0 commit comments