Hi Interesting. Would this be a way to reduce the time spent in up to date checks? It would be a big win if the daemon could flags a task as needing to be run on a change.
I am assuming you are thinking of using something like the FileAlterationObserver in commons-io? Philip On Wed, May 16, 2012 at 3:48 PM, Luke Daley <[email protected]> wrote: > I've been surveying the Javascript tooling landscape recently. > > One thing that's very common is to have daemon processes that watch files and > perform some action on change. Consider the case where you want to write > CoffeeScript, but compile it down to JavaScript and deploy that. During the > development cycle, you want something to do this compilation as soon as you > save a change so that when you refresh the browser you see the change > (because the javascript has been updated). > > With javascript, there can be a few different processing phases. e.g. > CoffeeScript → JavaScript → compressed JavaScript → bundled JavaScript > (combined into one file). You way want to use this final output during the > development process. > > Another case for this is continuous testing. A lot of the javascript testing > tools require a html bootstrapping page that does something like set the test > classpath and kick off the tests. You really want this to be generated, > managing the “classpath” dynamically. > > All of the maven javascript tooling plugins that do this hand roll their own > daemon process management, which is usually just starting the process. > > There are non javascript cases for this too. > > For war development, it would be nice to have something like > “processResources” run whenever an input file changes (as they may be > filtered). For our html slides, I'd like them to be compiled to html whenever > I changed the input markdown. > > It strikes me that we may be able to come up with a solution that could turn > almost any task into what I'm calling a “live task”. Since we know what the > inputs are we could monitor them and trigger the task when they change, no > matter what the task is doing. I suspect that would be the easy part though. > Managing and providing control over these daemon processes would likely be > the most costly to implement, as well as providing insight into what they are > doing. > > Rather exciting possibility though. If I'm working in a java module with unit > tests, I could just “liven” the test task for that module and achieve > continuous testing (granted, you'd want to be plugged into a power source if > you did this). I'm not aware of another tool that provides this feature > generically, for any kind of task. > > -- > Luke Daley > Principal Engineer, Gradleware > http://gradleware.com > > > --------------------------------------------------------------------- > To unsubscribe from this list, please visit: > > http://xircles.codehaus.org/manage_email > > --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
