jquery/download.jqueryui.com — pull request #146 by rxaviers (2013-05-22 20:40:02+00:00)
Title: Make DB not dependent on jquery-ui generating a build

Summary: (the goal)
- To build jquery-ui (concatenate, minify, change banner, change `@VERSION` variable, etc) by our own. This is: drop requirement to prepare the jquery-ui files by running its `build`, and `release` tasks. (Obs: DB still requires to prepare the jquery-ui files running its `manifest` task.)
- Avoid to break anything, including third-parties (jqueryui.com and jquery-ui with its tasks that depends on DB).
- Facilitate the cutoff duplicate parts work with jquery-ui, ie. bring release process from jquery-ui into DB.

Tests: (making sure this PR is good)

1. jshint and `npm test`, of course. Actually, they pass in each commit separated.
1. Make sure we keep building good solid packages. Follow a [diff view](https://github.com/rxaviers/download.jqueryui.com/commit/ca52429d522b10ed5de31a93829cd22f80de617c#diff-14) between the package downloaded from live site vs. a package downloaded with the code of this PR. Note you will find differences: (a) ignore the images, (b) this PR actually fixes things (see below).
1. On jquery-ui, `grunt generate_themes` and `grunt release_themes`. Passes.
1. On jqueryui.com, `grunt build-download build-packages`. Needs a slight change PR .

Changes: (the details)
- Make DB not dependent on jquery-ui release task. Along with that, I've renamed the Release lib for jQueryUI (and `release` path for `jquery-ui`).
- Make DB not dependent on jquery-ui build task. Note, it's using the default options of uglifyjs-2 and sqwish (for css).
- Cache built files. Since we are building it, it's being cached for performance. Actually, I've split the build (Builder) of the packaging (Packer) part. And actually2, since I've split them, it was more clear that we could cache more things. So, downloads are 12.5% faster.
- Organization. I made files manipulation more uniform across jQueryUI, Builder, Packer libs. They all use Files, which extends an Array and adds methods to make its usage more clean in Packer (see into, and rename).

--
Related PRs
- https://github.com/jquery/download.jqueryui.com/pull/139