From e55ece8b45cebd65c9d8007d9bc29ca3873684dc Mon Sep 17 00:00:00 2001 From: Harminder Virk Date: Mon, 22 Apr 2024 11:42:13 +0530 Subject: [PATCH] chore: replace np with release-it --- package.json | 27 +++++++++++++++++++-------- 1 file changed, 19 insertions(+), 8 deletions(-) diff --git a/package.json b/package.json index 878c58b..4877c19 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "precompile": "npm run lint && npm run clean", "compile": "tsup-node && tsc --emitDeclarationOnly --declaration", "build": "npm run compile", - "release": "np", + "release": "release-it", "version": "npm run build", "format": "prettier --write .", "prepublishOnly": "npm run build", @@ -63,8 +63,8 @@ "eslint": "^8.56.0", "github-label-sync": "^2.3.1", "husky": "^9.0.11", - "np": "^10.0.5", "prettier": "^3.2.5", + "release-it": "^17.2.0", "ts-node": "^10.9.2", "tsup": "^8.0.2", "typescript": "^5.4.5" @@ -95,12 +95,6 @@ "access": "public", "tag": "latest" }, - "np": { - "message": "chore(release): %s", - "tag": "latest", - "branch": "main", - "anyBranch": false - }, "c8": { "reporter": [ "text", @@ -126,5 +120,22 @@ "dts": false, "sourcemap": true, "target": "esnext" + }, + "release-it": { + "git": { + "commitMessage": "chore(release): ${version}", + "tagAnnotation": "v${version}", + "tagName": "v${version}" + }, + "hooks": { + "before:init": [ + "npm test" + ] + }, + "github": { + "release": true, + "releaseName": "v${version}", + "web": true + } } }