tag:blogger.com,1999:blog-8345036448224428874.post6432177132202552510..comments2021-07-26T03:48:25.601-06:00Comments on Thread.current.to_s: Let's use real languages for buildsAlexey Verkhovskyhttp://www.blogger.com/profile/00949972013936326795noreply@blogger.comBlogger13125tag:blogger.com,1999:blog-8345036448224428874.post-86547571013913878312009-03-10T10:26:00.000-06:002009-03-10T10:26:00.000-06:00You make some good points.To be fair to Ant, you c...You make some good points.<BR/><BR/>To be fair to Ant, you can mitigate a lot of the issues you describe by copious use of the <groovy> task. AFAIK Gant is basically a layer of abstraction on top of the Groovy AntBuilder, which this task also provides access to.<BR/><BR/>I'm project owner of Kundo - https://kundo.dev.java.net - which also uses AntBuilder to squeeze that extra something out of good old Ant.Anonymoushttps://www.blogger.com/profile/10171930407806075864noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-87094918310561629502009-03-09T19:31:00.000-06:002009-03-09T19:31:00.000-06:00Using the same language in various parts of the pr...Using the same language in various parts of the project, including the build script, has some merit. For one thing, it makes it that much easier for newcomers to pick it up.<BR/><BR/>The thing about Ant (Nant, MSBuild, Maven) is that it's not Java (or C#), anyway. It's freaking angled brackets! Which is really easy for a computer to parse, but that is the only redeeming feature of XML as a language syntax.Alexey Verkhovskyhttps://www.blogger.com/profile/00949972013936326795noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-48492724747163845672009-03-09T19:26:00.000-06:002009-03-09T19:26:00.000-06:00Yes. Although I have never had a reason to look in...Yes. Although I have never had a reason to look into Gant beyond demos, but it does look like the sort of build technology I'm talking about. Same goes for buildr.Alexey Verkhovskyhttps://www.blogger.com/profile/00949972013936326795noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-19111351109901541092009-03-09T12:55:00.000-06:002009-03-09T12:55:00.000-06:00I know you're probably going to get a million sugg...I know you're probably going to get a million suggestions, so I figure I'd throw mine in as well. :) Have you looked at GANT? (http://gant.codehaus.org/) It lets you write ANT build files in Groovy, giving you a real powerful scripting way of doing builds. (Check out its buildfile for some examples of what it can do.)Unknownhttps://www.blogger.com/profile/03611979960859306917noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-53335750073741614202009-03-09T09:26:00.000-06:002009-03-09T09:26:00.000-06:00I work for a strictly .NET-on-Windows company, but...I work for a strictly .NET-on-Windows company, but we still use rake for building. The actual compilation is still done with MSBuild, but we have a lot of other tasks written in ruby, like migrating databases, managing IIS tasks, etc. Rake really worked out great for us.<BR/><BR/>I don't get why some programmers feel that the tools they use to get the job done everyday must be written in the same language or platform that they program on.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-14796143347386967642009-03-09T07:13:00.000-06:002009-03-09T07:13:00.000-06:00You say you would use Rake for building Java. Ever...You say you would use Rake for building Java. Ever tried Buildr http://buildr.apache.org/ or the now seemingly sleeping http://raven.rubyforge.org/ ?Jonas Elfströmhttps://www.blogger.com/profile/18088865137364783994noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-22154101391048192582009-03-09T06:44:00.001-06:002009-03-09T06:44:00.001-06:00I think this may be difficult. Java is so verbose ...I think this may be difficult. Java is so verbose that ant chose XML files (yuck).<BR/><BR/>Ruby is so short and elegant that you can use it.<BR/><BR/>But what would you do in Java? The Java solution will always be longer.shevyhttps://www.blogger.com/profile/09636171104216432368noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-37125302575473127462009-03-09T06:44:00.000-06:002009-03-09T06:44:00.000-06:00Making humans edit XML should be a crime against h...Making humans edit XML should be a crime against humanity.<BR/><BR/>I've had good luck using scons for some of my C++ stuff though.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-17553470382864186082009-03-07T15:40:00.000-07:002009-03-07T15:40:00.000-07:00I completely agree with your post. I was on a proj...I completely agree with your post. I was on a project once where the ant tasks became non-trivial. Once it got to the point that we were throwing and catching exceptions in ant, we realized that we crossed the line from declarative build configuration to scripting, and it sucked. Hard.<BR/><BR/>By comparison, rake files are a more succinct way of doing the same simple stuff that ant is good at, but easily transitions into the hard stuff that ant is bad at.Krishttps://www.blogger.com/profile/17169486069763932973noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-77082394838240454502009-03-07T11:22:00.000-07:002009-03-07T11:22:00.000-07:00I prefer it the other way around. Have a Rake (Gro...I prefer it the other way around. Have a Rake (Groovy, Scons, what have you) build, use ant *tasks* in it if they save time. <BR/><BR/>Reason: Ant sucks (compared to Rake) even for such things as expressing task dependencies (especially when they change based on the target environment), for skipping tasks when task outputs are up to date with their sources, etc. It's not impossible to do any of it in Ant, just an order of magnitude harder.Alexey Verkhovskyhttps://www.blogger.com/profile/00949972013936326795noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-53202486494553891112009-03-07T06:00:00.000-07:002009-03-07T06:00:00.000-07:00While I agree that programming in XML is wrong, I ...While I agree that programming in XML is wrong, I wonder if the exercise above is asking the tool to do too much.<BR/><BR/>Ant just isn't good at taking into account different environments, etc. Tools like cargo help you make a developer build that has a simple deploy step. I like to have an ant build that focuses on making artifacts (wars, configurations, db files) that you can deploy. I always put those artifacts onto a filesystem in a kind of repository and then try and use something else for deployment.<BR/><BR/>If it all possible you should be writing that second script in a dynamic language. Trying to extend Ant using Antcontrib is like putting mag wheels and a whale tail on a VW bug: it still won't be a Porsche.Julianhttps://www.blogger.com/profile/06148753904642162513noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-62389136140947467122009-03-06T15:45:00.000-07:002009-03-06T15:45:00.000-07:00Ant works wonders for a narrow set of tasks. As so...Ant works wonders for a narrow set of tasks. As soon as you step outside that set, it becomes excruciating pain. And yes, we do use antcontrib - it slightly extends that set. Rake still kicks Ant's ass.<BR/><BR/>FWIW, this opinion is certainly subjective, but it's not based on hype. I had to deal with non-trivial builds in every technology mentioned in the post, except Maven.Alexey Verkhovskyhttps://www.blogger.com/profile/00949972013936326795noreply@blogger.comtag:blogger.com,1999:blog-8345036448224428874.post-2603496948964576392009-03-06T10:40:00.000-07:002009-03-06T10:40:00.000-07:00Don't forget that Linux/Unix has had this ability ...Don't forget that Linux/Unix has had this ability for years with it's various scripting langauges. I used REXX for builds under OS/2, Windows, etc. Ant works wonders if you add Antcontrib which adds some more programming to it. Rake is just another tool. There are multiple ways to re-invent the same wheel. Use the correct tool for the correct job. I personally think Ruby and it's related items are over hyped, until the next great thing comes along.David Carverhttps://www.blogger.com/profile/09341170413510029324noreply@blogger.com