0.0.1 • Published 3 years ago

git-push-monitor v0.0.1

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

monitor assign files change when git push

you should use it with husky、git

ueage

npm install gitMonitor -D

config in package.json

assign the files and use cli in husky

  ...
  "repository": {
    "type": "https",
    "url": "https://xxxxxxxx",
    "monitorFiles": [
      "./package.json",
      ...
    ]
  },
    "husky": {
    "hooks": {
      ...
      "pre-push": "gitMonitor './trigger.js'",
      ...
    }
  },
  ...

trigger function

you can send diff result to chat group

module.exports = function (diffRes) {
  console.info(diffRes) //
  .....
}