Added an easy to use config/assemblage.rb file for ordering #2
Added an easy to use config/assemblage.rb file for ordering #2taf2 wants to merge 14 commits intovoxxit:masterfrom
Conversation
…ript and style order
…blage' assuming it's pushed to rubyforge otherwise gem 'assemblage', :git => 'git://github.com/taf2/assemblage.git'
…d a capistrano task to upload generated files
|
Hi Josh, wondering if you would be interested in these changes. I'd also like to get assemblage into rubygems. |
|
Hi there! Sorry for such a late reply. Been quite busy with other projects. I'd like to see some more tests for these changes before I put them into production. Also, since this is quite a large change, are you sure this allows for backwards compatibility? Why were you putting the compiled .yml files into the config/ directory? Why not into the tmp/ directory, and then blow them away at the end of the task? Do they serve some purposes other than for what I'm looking at in the code? Thanks for the contributions! |
|
Hi, no worries about delay - I get busy too. Yeah, I agree about moving the .yml files into /tmp and deleting near the end. I'm using this in 2 production sites already and it's working really well... As for backwards compat - I think it should be, but I've not been able to test it really... As I recall, the configuration file only kicks in when it's present and otherwise things will work exactly as they did before. When I get some cycles I'll circle back around to clean up the temporary yml files. |
I really like the approach of zero configuration - but in the case of requiring a specific order for the included scripts I think a lite configuration file is necessary. The file only exposes a very simple API for describing specific bundles to provide ordering. If the bundle is not configured it will continue to use the default behavior of ordering them alphabetically. I also had to refractor things a bit to provide some basic test coverage of the added configuration feature.
I have an example configuration file here: https://github.com/taf2/assemblage/blob/master/test/config/assemblage.rb
Hope you find this change useful also. Thanks for the great work on the packager!