File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7171 - name : Generate release notes
7272 id : release_notes
7373 run : |
74- # Get previous tag
75- PREV_TAG=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "")
74+ # Get the previous version tag (second most recent v* tag by version order)
75+ # This is more reliable than using git describe which follows commit ancestry
76+ CURRENT_TAG=${{ github.ref_name }}
77+ PREV_TAG=$(git tag -l 'v*' --sort=-version:refname | grep -v "^${CURRENT_TAG}$" | head -1)
78+
79+ if [ -z "$PREV_TAG" ]; then
80+ echo "No previous tag found"
81+ else
82+ echo "Previous tag: $PREV_TAG"
83+ fi
7684
7785 # Get current date
7886 RELEASE_DATE=$(date +%Y-%m-%d)
@@ -153,8 +161,8 @@ jobs:
153161 EOF
154162 fi
155163
156- # Add Other changes if exists and no features/fixes
157- if [ -z "$FEATURES" ] && [ -z "$FIXES" ] && [ - n "$OTHER" ]; then
164+ # Add Other changes if exists
165+ if [ -n "$OTHER" ]; then
158166 cat >> release_notes.md <<EOF
159167
160168 ## Changes
Original file line number Diff line number Diff line change 11{
22 "name" : " @formo/analytics-node" ,
3- "version" : " 1.0.1 " ,
3+ "version" : " 1.0.2 " ,
44 "main" : " dist/cjs/src/index.js" ,
55 "license" : " MIT" ,
66 "module" : " dist/esm/src/index.js" ,
77 "types" : " dist/cjs/src/index.d.ts" ,
8+ "repository" : {
9+ "type" : " git" ,
10+ "url" : " git+https://github.com/getformo/sdk-node.git"
11+ },
12+ "publishConfig" : {
13+ "access" : " public" ,
14+ "provenance" : true
15+ },
816 "scripts" : {
917 "build" : " npm run build:cjs && npm run build:esm" ,
1018 "build:cjs" : " tsc --project tsconfig.cjs.json" ,
You can’t perform that action at this time.
0 commit comments