Skip to content

Commit e50a6f8

Browse files
author
Alan Agius
committed
fix(installer): fix issue that installer was not being triggered.
1 parent 4196d7b commit e50a6f8

2 files changed

Lines changed: 4 additions & 5 deletions

File tree

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@speedy/commit-msg-hook",
3-
"version": "1.1.2",
3+
"version": "1.1.0",
44
"description": "GIT commit-msg validator hook",
55
"main": "./dist/index.js",
66
"repository": {
@@ -32,8 +32,7 @@
3232
"preversion": "npm test",
3333
"version": "npm run build && npm run changelog",
3434
"postversion": "git commit --all -m \"chore(all): update for release\" && git push && git push --tags",
35-
"postinstall": "node ./dist/installer install",
36-
"preuninstall": "node ./dist/installer uninstall"
35+
"release": "ts-node ./tools/modify-package && npm publish && git checkout ."
3736
},
3837
"dependencies": {
3938
"lodash": "^4.17.4"

tools/modify-package.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ import { readFileSync, writeFileSync } from "fs";
33
const pkgContents = JSON.parse(readFileSync("./package.json", "utf-8"));
44

55
const scripts = { ...pkgContents.scripts, ...{
6-
postinstall: "node ./dist/installer install",
7-
preuninstall: "node ./dist/installer uninstall"
6+
install: "node ./dist/installer install",
7+
uninstall: "node ./dist/installer uninstall"
88
}};
99

1010
writeFileSync("./package.json", JSON.stringify({

0 commit comments

Comments
 (0)