From ebd761ee96ad8ae43da61305301bb7e96d1b47a9 Mon Sep 17 00:00:00 2001 From: AVVS Date: Sun, 30 Jul 2017 15:22:50 -0700 Subject: [PATCH] fix(postinstall): use rimraf to dispose of pre-git/simple-commit-message --- scripts/setup-semantic-release.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/setup-semantic-release.js b/scripts/setup-semantic-release.js index 5d5707a..784e37b 100644 --- a/scripts/setup-semantic-release.js +++ b/scripts/setup-semantic-release.js @@ -5,6 +5,7 @@ const debug = require('debug')('github-post-release'); const path = require('path'); const fs = require('fs'); +const rimraf = require('rimraf'); const isForced = process.argv.some(a => a === '--force'); @@ -77,6 +78,6 @@ console.log('⚠️ Use "semantic-release-cli setup" to complete setting up sema console.log('⚠️ For scoped packages add {"publishConfig":{"access": "public"}} to package.json'); if (fs.existsSync(preGitOldModules('simple-commit-message'))) { - console.log('⚠️ Removed "simple-commit-message" from git-it dependencies'); - fs.rmdirSync(preGitOldModules('simple-commit-message')); + rimraf.sync(preGitOldModules('simple-commit-message')); + console.log('⚠️ Removed "simple-commit-message" from pre-git dependencies'); }