@modernpoacher/hooks 1.0.413 → 1.0.415

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,18 @@
1
1
  #!/bin/sh
2
2
  . "$(dirname "$0")/_/husky.sh"
3
3
 
4
- npx cross-env DEBUG=@sequencemedia/hooks* node .husky/post-commit.mjs
4
+ get_package_changes () {
5
+ local CURRENT_BRANCH
6
+ CURRENT_BRANCH=$(git rev-parse --abbrev-ref HEAD)
7
+
8
+ git diff HEAD~1..HEAD~0 -- "origin/$CURRENT_BRANCH" package.json
9
+ }
10
+
11
+ has_package_changes () {
12
+ [ ! -z "$(get_package_changes)" ]
13
+ }
14
+
15
+ if has_package_changes;
16
+ then
17
+ npx cross-env DEBUG=@modernpoacher/hooks* node .husky/post-commit.mjs
18
+ fi
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@modernpoacher/hooks",
3
- "version": "1.0.413",
3
+ "version": "1.0.415",
4
4
  "description": "Git Hooks",
5
5
  "keywords": [
6
6
  "git",
@@ -34,10 +34,10 @@
34
34
  "@babel/cli": "^7.21.5",
35
35
  "@babel/core": "^7.22.1",
36
36
  "@babel/eslint-parser": "^7.21.8",
37
- "@babel/preset-env": "^7.22.2",
37
+ "@babel/preset-env": "^7.22.4",
38
38
  "core-js": "^3.30.2",
39
39
  "eslint": "^8.41.0",
40
- "eslint-config-standard": "^17.0.0",
40
+ "eslint-config-standard": "^17.1.0",
41
41
  "eslint-plugin-import": "^2.27.5",
42
42
  "eslint-plugin-node": "^11.1.0",
43
43
  "eslint-plugin-promise": "^6.1.1",
package/src/common.mjs CHANGED
@@ -121,7 +121,7 @@ export function patchPackageVersion () {
121
121
 
122
122
  return (
123
123
  new Promise((resolve, reject) => {
124
- exec('npm version patch -m %s -n', OPTIONS, (e) => (!e) ? resolve() : reject(e))
124
+ exec('npm version patch -m "%s" -n --no-commit-hooks', OPTIONS, (e) => (!e) ? resolve() : reject(e))
125
125
  })
126
126
  )
127
127
  }