From 37c89a26c76ca765824e06503bad4388c8c0f7ab Mon Sep 17 00:00:00 2001 From: John Doe Date: Wed, 26 Feb 2025 14:09:15 +0530 Subject: [PATCH] chore: add changelog check before publishing and create changelog for version 1.0.1 --- changelogs/v1.0.1-changelog.md | 14 ++++++++++++++ package.json | 3 ++- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 changelogs/v1.0.1-changelog.md diff --git a/changelogs/v1.0.1-changelog.md b/changelogs/v1.0.1-changelog.md new file mode 100644 index 0000000..b8812cf --- /dev/null +++ b/changelogs/v1.0.1-changelog.md @@ -0,0 +1,14 @@ +## Changes + +**User Agent** + +- Added User-Agent header with version info + + +## Breaking Changes + +None. + +## Migration Guide + +No migration needed for this release. diff --git a/package.json b/package.json index d84f88f..758b435 100644 --- a/package.json +++ b/package.json @@ -81,7 +81,8 @@ "coverage": "vitest run --coverage", "check:state": "git diff --quiet && git diff --cached --quiet || { echo 'Git working directory is not clean. Please commit or stash changes before publishing.'; exit 1; }", "check:branch": "if [ $(git symbolic-ref --short HEAD) != 'master' ]; then echo 'You must be on the master branch to publish.'; exit 1; fi", - "prepublishOnly": "npm run check:state && npm run check:branch && npm run build" + "check:changelog": "VERSION=$(node -p \"require('./package.json').version\") && if [ ! -f \"changelogs/v${VERSION}-changelog.md\" ]; then echo \"No changelog file found for version ${VERSION}.\"; exit 1; fi", + "prepublishOnly": "npm run check:state && npm run check:branch && npm run check:changelog && npm run build" }, "engines": { "node": ">=20"