Skip to content

Instantly share code, notes, and snippets.

@davidworkman9
Created October 8, 2014 13:14
Show Gist options
  • Save davidworkman9/d1e1935ce8377c09ea6b to your computer and use it in GitHub Desktop.
Save davidworkman9/d1e1935ce8377c09ea6b to your computer and use it in GitHub Desktop.
Generate Webstorm ignores for .build directories in Meteor
#!/usr/bin/env node
var fs = require('fs');
console.log('Copy the following into .idea/PROJECT_NAME.iml inside of module>component>content:\n');
console.log(
['<excludeFolder url="file://$MODULE_DIR$/app/.meteor" />'].concat(
// read the packages directory
fs.readdirSync(process.argv[2] || 'packages')
// filter out hidden folders/files
.filter(function (d) {
return d[0] !== '.';
})
// map to XML template
.map(function (x) {
return '<excludeFolder url="file://$MODULE_DIR$/app/packages/' + x + '/.build.' + x + '" />';
})).join('\n')
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment