Skip to content

Commit df9c26a

Browse files
authored
1.0.2 (#10)
* Add repository and publishConfig * Update release.ml * 1.0.2
1 parent 0b91807 commit df9c26a

3 files changed

Lines changed: 23 additions & 7 deletions

File tree

.github/workflows/release.yml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,16 @@ jobs:
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

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,18 @@
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",

0 commit comments

Comments
 (0)