NEPA.js Gulp Demo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Task: NepaJS | |
Does some silly things for NEPA JS | |
*/ | |
gulp.task('nepajs', function() { | |
var nepajsURL = 'https://www.meetup.com/NEPA-js/', | |
nepaJSDirWin = '/mnt/c/Users/tucker/Desktop/', | |
nepaJSDirMac = '/Users/cdevroe/Desktop/', | |
nepaJSSlackMsg = ":bebop: Hello NEPA.js July Meetup Attendees!! \n I'm going to run a few tasks for you. \n\n"; | |
mkdirp(nepaJSDirWin+'nepajs', function (err) { | |
if (err) { | |
console.error(err) | |
} else { | |
nepaJSSlackMsg += "1. Created a directory called nepajs on your desktop. \n"; | |
fs.writeFile(nepaJSDirWin+'nepajs/nepajs.txt', "Hello NEPA JS. I'm in ur txtfilz, scrwn up ur shiznit.", (err) => { | |
if (err) { console.error(err); } else { | |
nepaJSSlackMsg += "2. Created a text file in that directory. \n"; | |
//opn(nepajsURL); | |
exec('cmd.exe /c start ' + nepajsURL); | |
nepaJSSlackMsg += "3. Opened your browser to: " + nepajsURL + " \n"; | |
bebop.chat(nepaJSSlackMsg + "\n Wasn't that much easier than doing it yourself?", null, function(){ | |
console.log("All tasks complete."); | |
process.exit(); | |
}); | |
return; | |
} | |
}); | |
} | |
}); // end mkdirp | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment