I love to Grunt & Gulp

Task Runners – like Grunt & Gulp are such time-savers!

Reason: Automation!!!
Remove the “grunt work” by making tasks repeatable & standardize build/deploy scenarios, win-win!

Now, I am sure many of the savvy techies in you would have already checked out Grunt/Gulp and using them in your own ways. Task Runners have been in the wild for some time now, with excellent tutorials to get you started & so I will not delve into the details of how/what/why of these items.

The point of this article is for an interesting thought I had:

  • Is there any real need for such a framework(s) in your code in the first place?
  • Aren’t we introducing additional components + complexity into our code by having such items?

Is there an alternative to get the automation benefits of Task Runners, without the need for additional complexity and/or bloat of adding such frameworks into your code?

When this thought occurred to me late last night (yes, during a New Year’s Eve Party & yes – I am THAT kind of nerd!), I just could not wait to get started & give it a twirl in the NPM world & see where I get to.

More specifically, I was thinking of code along the lines of:

// code in package.json
scripts: {
"build": "npm build:script && npm build:css && npm:deploy",
"build:script": "browserify src/index.js -o dist/lib.js",
"build:css": "less"

As soon as I started along these lines, a small voice in my head went:
did someone think of such a solution before & if yes, what does that code look like?
Answer: Google says someone already has got there first.

As I tip my hat to the master, I also realize that I have been 2 months 1 day slower in coming up with this thought & 23 days slower in publishing a solution


I would strongly recommend to read through his material before continuing.

My personal opinion is that he is on to something here & I do see all the benefits in the solution.

Question: will I use the proposed solution in my own code-base?
Answer: While I really like the solution, is it worth the cost of readability for someone to “get” what it really stands for? I don’t know.

I will let this one simmer for a while & eventually wean off Grunting/Gulping.

I am too much in habit at this point in time.

Happy 2015!


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s