npm hook
管理注册表挂钩
概要
npm hook ls [pkg]
npm hook add <entity> <url> <secret>
npm hook update <id> <url> [secret]
npm hook rm <id>
示例
添加一个钩子来观察一个包的变化:
$ npm hook add lodash https://example.com/ my-shared-secret
添加一个钩子来查看属于用户 substack
的包:
$ npm hook add ~substack https://example.com/ my-shared-secret
添加一个钩子来监视范围 @npm
中的包
$ npm hook add @npm https://example.com/ my-shared-secret
列出所有活动的钩子:
$ npm hook ls
iGtRnnlqu4YVvxSkan8eZMcndf0tfiVYvehOaWt9HsUCvSLgT/OxMQREFzAPG+nsokN+sp07TDQfUNujigJdzQ==
$ npm hook ls lodash
Lk4KWsx8Q8rxupu/fBH8FSlwZyeBGa2KMVYvLbtpkNI=
$ npm hook update id-deadbeef https://my-new-website.here/
ncMdUQnqg24pa5Kux/5ZPXe/P/eO5VjW/URhXJA6Jl4=
$ npm hook rm id-deadbeef
描述
TtoLJKw6yPZlyNzQjxIUh4DOZp7tkUPDCmE0P3lCgNGOP90lzvC8Fe3lZ7A+JfWamAPRWuseZ8rR5yLNfQ2dm5FsE6tAX9+BDB29cQZXSdHg+AZ+Q6Ntobqm6hLpz1QLPEPBz63xOkhtUrFeaLHvnTYhmAwDmhj9Gvd8es7SJlM=
O46L5Niep5IOqVadnsBRK3Xacg8G3hH0WDo/jKgp/1PIGuLSPQ8bn16HaoWL1Q4ETLIh03HGVeTUkr0eF0ZlttnzYOH2G2elmLUsdUoT2jJyWPSKRe2H3jCwVyyrKAnJD7LBGSWdP0bj/x8Psv1BN5LgZ8I0OZ9F1EQg8DrTtOnDMUa0npIpvB27l+4RFt99lKQTrBWOJO1lyIznY8k+mYBYaHW8i1kFVt6Y0aM5A7V4IWZiDCUqcuNxP946q7bb
W0A+cXC5PxsIqvwnto0n9wh1t8toiCb2XcSXrC4S5zvvJgxbnBuLu3XG5GxaILsn
C88te/+0C0nxuUgaqjN0Ulyo9QQ3rDkgZrf1ehafmAceT4Th5hH7SqJ81YcfnEhvco0YcqJzHjRSQqN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