From e8f0dc749b2d5c564b74b6df4854a1b5e40dc5e8 Mon Sep 17 00:00:00 2001 From: isaacs Date: Sat, 15 Sep 2018 17:22:32 -0700 Subject: [PATCH] auto-publish scripts --- chownr.js | 4 +--- package.json | 5 ++++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/chownr.js b/chownr.js index 2b740b0..df3753f 100644 --- a/chownr.js +++ b/chownr.js @@ -12,10 +12,8 @@ const nodeVersion = process.version let readdir = (path, options, cb) => fs.readdir(path, options, cb) let readdirSync = (path, options) => fs.readdirSync(path, options) /* istanbul ignore next */ -if (/^v4\./.test(nodeVersion)) { +if (/^v4\./.test(nodeVersion)) readdir = (path, options, cb) => fs.readdir(path, cb) - readdirSync = (path, options) => fs.readdirSync(path) -} const chownrKid = (p, child, uid, gid, cb) => { if (typeof child === 'string') diff --git a/package.json b/package.json index 358c50f..49d3942 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,10 @@ "tap": "^12.0.1" }, "scripts": { - "test": "tap test/*.js" + "test": "tap test/*.js --cov", + "preversion": "npm test", + "postversion": "npm publish", + "postpublish": "git push origin --all; git push origin --tags" }, "license": "ISC" }