Sprocket is a Ruby library for managing JavaScript dependencies. It makes it possible to declare dependencies in specially formatted comments in the JavaScript files, and have all the required files concatenated server side. (Read more here: http://getsprockets.org/)
Where I work, we have a real need for such a framework, but it has to be in the form of a Java library.
Does such a thing exist? What other solutions have you come up with to manage JavaScript dependencies?
You can also use juicer to merge javascript files although it’s also written in ruby.
Another option that, I suppose, will suit you is using combiner by Nicholas C. Zakas if you do not need all the features of juicer and sprockets. It is pretty simple, written in java (.jar) and the source can be found in author’s repository. You can also fork the source in order to tune it according to your needs.