UNPKG

comb-cli

Version:

comb cli

16 lines (15 loc) 496 B
#!/usr/bin/env node const fs = require('fs'); const path = require('path'); const process = require('process'); const rootPath = process.cwd(); require('shelljs/global'); require('colors'); module.exports = function createIgnore () { const ignorePath = path.resolve(rootPath, '.gitignore'); const defaultIgnorePath = path.resolve(rootPath, '.gitignoreConfig'); if (!test('-f', ignorePath)) { cp('-rf', defaultIgnorePath, ignorePath); } rm('-rf', defaultIgnorePath); }