Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ Run from the root location of your project:
```
increase-memory-limit
```
Optional parameter
* --hideOutput - Hide output of files which has been written

Running from NPM task
---
Expand Down
6 changes: 5 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const glob = require('glob');
const fs = require('fs');

const maxOldSpaceSize = process.env.LIMIT || 10240;
const hideChangeFileOutput = process.argv.indexOf('--hideOutput') > -1;
const cwd = process.cwd() + path.sep;

glob(path.join(cwd, "node_modules", ".bin", "*"), function (err, files) {
Expand Down Expand Up @@ -37,7 +38,10 @@ glob(path.join(cwd, "node_modules", ".bin", "*"), function (err, files) {
}

fs.writeFileSync(file, patchedContents);
console.log(`'${file.replace(cwd, "")}'`, "written successfully.");
if(!hideChangeFileOutput) {
console.log(`'${file.replace(cwd, "")}'`, "written successfully.");
}

});

});