4 ms·
Why would you want to include grunt or gulp? Shell scripts do the job just as well and can be run from npm. Bash is streaming, parallel etc etc. You can do ever
by woah 11y ago
Why would you want to include grunt or gulp? Shell scripts do the job just as well and can be run from npm. Bash is streaming, parallel etc etc. You can do everything you want with &, &&, |, and >
- andy_ppp 11y agoDo you have a demo repo so we can learn from this, sounds pretty great. How do I watch files with bash and recompile changes (for example)? I'm certain it's all possible, and while grunt and gulp have lots of examples I never really like them.
- techterrier 11y agoHere's a couple of articles if you are interested in the gulp free approach: http://blog.keithcirkel.co.uk/why-we-should-stop-using-grunt/ http://blog.keithcirkel.co.uk/why-we-should-stop-using-grunt... http://blog.keithcirkel.co.uk/how-to-use-npm-as-a-build-tool/ http://blog.keithcirkel.co.uk/how-to-use-npm-as-a-build-tool...
- idonthaveaname 11y agoThe Keith Cirkel articles, mentioned earlier, are great. I also found this one, today: http://beletsky.net/2015/04/npm-for-everything.html http://beletsky.net/2015/04/npm-for-everything.html It's less detailed, but also shorter and easier to digest.
- paulojreis 11y agoMy shell scripting skills aren't really that good. I feel that this might be true for most front-end developers. A JS based task runner is nice for me, as a I can harness the language I use on a daily basis (as well as the community with jobs similar to mine). Maybe if I used more bash than JS I would have a different opinion. Language preferences/fluency aside, I feel that there's much to gain from the JS "hash-based" way of expressing objects which are used as configuration objects (which can be dynamic) in task runners. I'm not aware of an easy alternative to this in shell scripting, but this is probably due to my ignorance on the subject).
- freshyill 11y agoYeah why would anybody want to use this convenient thing thing when you could just write some shell scripts.
- dimgl 11y agoUp until recently I would not have agreed with you. However, recently I've skipped on Gulp and Grunt and it has helped me with various things: * Saves me time so I don't need to figure out why a Gulp/Grunt script is behaving erratically, such as a watch that crashes even though exceptions are being caught for it * Reduces my development depenencies, which helps with the following two things: * There's less of a chance that there will be a package that needs to be built that will crash and burn on Windows * I don't need to download a shit ton of stuff from NPM every time I clone from Git * Helps me think about my architecture critically as I don't want to do anything too complicated outside of Gulp/Grunt * I don't need to wait for someone to make a plugin for a test runner
- tehbeard 11y agoCan shell scripts do the same job? yes. Do I want to deal with writing the code / instructions to: * Explain how to setup/install the build tools. * Account for differences in shell env. * Explain to windows users to get cygwin/whatever, or make a separate set of scripts for them. No. Grunt/Gulp have the benefit of having a consistent cross OS package manager (npm), in a language that the coder is likely to be familiar with should they need to tweak it.