Live data from Hacker News

Grunt and RequireJS are out, it's all about Gulp and Browserify

100percentjs.com

131–140 of 163 posts

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#131
post #28

Earlier quoted context omitted.

Why even use Make? I just use shell scripts for automation. The only case where you really need the incremental behavior of Make is C/C++ builds (and arguably it's increasingly inappropriate for this domain as well). For all other kinds of automation I just use shell scripts, since Make is mostly a horribly reinvented shell script dialect.

Autocompletion of make targets in the shell.

I wrote my own completion for that :) Here is the pattern I use:

   run.sh

   build() {
     ...
   }

   test() {
     ...
   }

   deploy() {
     ...
   }

   # This lets you do ./run.sh build foo bar at the command 
   # line.  The autocomplete scans for functions in .sh files
   # and fills them in as the first arg.

   "$@"

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#132
post #28

Earlier quoted context omitted.

Why even use Make? I just use shell scripts for automation. The only case where you really need the incremental behavior of Make is C/C++ builds (and arguably it's increasingly inappropriate for this domain as well). For all other kinds of automation I just use shell scripts, since Make is mostly a horribly reinvented shell script dialect.

Your post just punched me in the gut. I've spent the last couple of weeks playing the "front end build tool dance" (primarily a back end dev) to find a system I like and it simply never occurred to me I could write my own as a quick bash script or python if I think it'll grow. That's an embarrassing oversight.

Good :) Shell scripts will be around for a lot longer than any of those tools.

Shell is also significantly easier and faster, if you just want to say run jslint, then minify, etc.

I program in lots of languages, so shell is the first tool I reach for. Learning the language is enough; I don't have time for all these quirky build and deploy tools.

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#133
post #65
post #28

Earlier quoted context omitted.

Why even use Make? I just use shell scripts for automation. The only case where you really need the incremental behavior of Make is C/C++ builds (and arguably it's increasingly inappropriate for this domain as well). For all other kinds of automation I just use shell scripts, since Make is mostly a horribly reinvented shell script dialect.

Saying that Make is a horribly implemented Shell dialect clearly seems like a misrepresentation of Make to me. Make is a non-procedural way to describe the dependencies of your build process. You describe what you want as a result rather than the steps that the interpreter should follow. It's possible to like or dislike this approach but it's clearly qualitatively different from Shell scripting.

I understand that distinction, but my point is that for automation like running jslint or minify, the dependencies aren't that necessary. Those commands don't take very long, and often don't have long dependency chains.

Make basically adds a very small "declarative" dependency layer, and then reimplements the shell poorly:

   - variables (from the environment)
   - command tokenization
   - escaping rules
   - functions
   - if statements
   - include
   - globbing (in the target line)
   - various magic $ variables
   - process substitution
   - eval
   ... etc.
That is, it's a full fledged programming language with different syntax than shell, but mostly the same features. I guess what might do in some cases is have a very simple "actions.sh" shell script, and then a Makefile which ONLY has simple command lines calling into actions.sh. Any functions would be in bash rather than make.

This is actually nice because there is an "upgrade path". For most simple things, you can just stick with shell. But when you need the power of make, you can upgrade without rewriting anything -- just adding a short/readable makefile.

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#134

This is a tangential question, but how do front-end people feel about the constant change in the field? I worked in the front-end and followed the trends for years and have found the changes difficult to follow. In 1997, the rage was VB and lots of cottage companies set up and advertising custom ActiveX widgets, on the web one had to learn ColdFusion and HTML/CSS. In early 2000's, VB6 was retired in favor of .net and…

I'm frankly overwhelmed of learning and being exposed to new technologies. The physical draining feeling of learning new keywords to fulfill the same urges is as if I have watched 15 years of porn following from the grainy days of Jenna Jameson on VHS to the heady-days of Internet dial-up gonzo porn of the early 2000's that really explored anal (Gauge, Taylor Rain) to the streaming flash videos of Web 2.0 (Sasha Grey…

Yeah, I was not expecting that. Kind of offended. (a) I'm at work and (b) was not aware of the "splintered and social-mediafied porno-world" nor all its categories.

But props to a pun-intended use of the word "spent".

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#135
post #84

Earlier quoted context omitted.

> Grunt in particular doesn't bring anything to the table that bash scripts don't One thing that comes to mind is cross-platform builds, which in some scenarios is very useful.

Also, how do I call a JS function in a Bash script? There are lots of JS libraries that existed before Grunt that are useful to incorporate into a build system. If I was relying on Bash scripts, I'd have to write all sorts of wrappers in JS anyway.

#!/usr/bin/env node

What a heavy wrapper. ;-)

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#136

This is a tangential question, but how do front-end people feel about the constant change in the field? I worked in the front-end and followed the trends for years and have found the changes difficult to follow. In 1997, the rage was VB and lots of cottage companies set up and advertising custom ActiveX widgets, on the web one had to learn ColdFusion and HTML/CSS. In early 2000's, VB6 was retired in favor of .net and…

Repost, don't know the original author:

I agree, I can't keep up, I just finished learning backbone.js and now I've found out on HN that it's old news, and I should use ember.js, cross that, it has opinions, I should use Meteor, no, AngularJS, no, Tower.js (on node.js), and for html templates I need handlebars, no mustache, wait, DoT.js is better, hang on, why do I need an HTML parser inside the browser? isn't that what the browser for? so no HTML templates? ok, DOM snippets, fine, Web Components you say? W3C are in the game too? you mean write REGULAR JavaScript like the Google guys? yuck, oh, I just should write it with CofeeScript and it will look ok, not Coffee? Coco? LiveScript? DART? GWT? ok, let me just go back to Ruby on Rails, oh it doesn't scale? Grails? Groovy? Roo? too "Springy?" ok, what about node.js? doesn't scale either?? but I can write client side, server side and mongodb side code in the same language? (but does it have to be JavaScript?) ok, what about PHP, you say it's not really thread safe? they lie?? ok, let me go back to server coding, it's still Java right? no? Lisp? oh it's called Clojure? well, it has a Bridge / protocol buffers / thrift implementation so we can be language agnostic, so we can support our Haskell developers. Or just go with Scala/Lift/Play it's the BEST framework (Foresquare use it, so it has to be good). of course we won't do SOAP and will use only JSON RESTful services cause it's only for banks and Walmart, and god forbid to use a SQL database it will never scale

I've had it, I'm going to outsource this project... they will probably use a wordpress template and copy paste jQuery to get me the same exact result without the headache and in halfquarter the price

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#137
post #132

Earlier quoted context omitted.

Your post just punched me in the gut. I've spent the last couple of weeks playing the "front end build tool dance" (primarily a back end dev) to find a system I like and it simply never occurred to me I could write my own as a quick bash script or python if I think it'll grow. That's an embarrassing oversight.

Good :) Shell scripts will be around for a lot longer than any of those tools. Shell is also significantly easier and faster , if you just want to say run jslint, then minify, etc. I program in lots of languages, so shell is the first tool I reach for. Learning the language is enough; I don't have time for all these quirky build and deploy tools.

The embarrassing part is I automate everything with the shell and still never thought of it :).

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#138
post #50

And again I'll remind people what happened in Java land: ANT -> Ivy/Maven -> Gradle I'll state it clearly: Grunt. is. Ant. It's a mess to follow a build script and a ritual to make it work in a real life project. I expected a tool like gulp to come sweeping in and it did, I'm extremely happy about that and started migrating away from the horrible tooling that is Grunt. I never understood how people can tolerate Grunt…

I agree with you that "Grunt is ant". But when I look at that code example it seems like "Gulp is ant", too. It's just less verbose. I think that Lineman is the Maven equivalent in the JS world.

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#139

Earlier quoted context omitted.

I'm frankly overwhelmed of learning and being exposed to new technologies. The physical draining feeling of learning new keywords to fulfill the same urges is as if I have watched 15 years of porn following from the grainy days of Jenna Jameson on VHS to the heady-days of Internet dial-up gonzo porn of the early 2000's that really explored anal (Gauge, Taylor Rain) to the streaming flash videos of Web 2.0 (Sasha Grey…

Yeah, I was not expecting that. Kind of offended. (a) I'm at work and (b) was not aware of the "splintered and social-mediafied porno-world" nor all its categories. But props to a pun-intended use of the word "spent".

Isatmour, I apologize for offending you, I certainly didn't intend to impose pornography onto you nor condone porn addiction (for being a porn addict, I know that it is no laughing matter although I try to use humor to try to be honest and confront my issue). I guess I wanted to frame learning front-end framework as a kind of OCD/obsessive behavior similar to any positive or negative addition you or someone you know might have experienced and chose the "lowest common denominator" metaphor I could find: porn addiction. Again I apologize for this who may find it offensive or an emotional trigger. And for anyone who's reading this and have this issue, I def. recommend this book: "The Addictive Personality" (http://www.amazon.com/The-Addictive-Personality-Understandin...) which has helped me understand and reform my behavior.

Re: Grunt and RequireJS are out, it's all about Gulp and Browserify

#140

This is a tangential question, but how do front-end people feel about the constant change in the field? I worked in the front-end and followed the trends for years and have found the changes difficult to follow. In 1997, the rage was VB and lots of cottage companies set up and advertising custom ActiveX widgets, on the web one had to learn ColdFusion and HTML/CSS. In early 2000's, VB6 was retired in favor of .net and…

HTML/CSS, .net, PHP, LAMP, AJAX, Jquery, HTML5, Backbone, Grunt, PORN, Gonzo, Anal, Sasha Grey, Scala, Python, C++

Brb. Updating my LinkedIn profile, "originally a front-end developer, but later foray into Gonzo/Sasha Grey has really opened up my interest in implementing modern concurrency 'best practices' in the back-end."
Post reply on HN