rumblelabs/asset_sync — pull request #20 by jasonhutchens (2011-11-11 01:49:32+00:00)
Title: Fixes issues #16, #17, #18 and #19

These fixes introduce the following changes:

* `manifest` was added to configuration to specify the full path to the `manifest.yml` file generated by the asset pipeline
+ this allows the list of local files to upload to be read from the manifest file
* if `manifest` is not given, the list of files is generated by recursing into `public/assets` as before
+ however, the list of local files is now cached to prevent this from happening more than once
* the `assets` sub-directory is now specified when locating files in the S3 bucket, meaning that the bucket may safely contain non-asset files in other sub-directories
* the full list of asset files already on S3 is now retrieved, rather than the first 1000, preventing unnecessary re-uploads and ensuring all old assets are deleted (if that configuration option was given)
* the list of files to upload is now correctly calculated:
+ it is now simply the local files minus the remote files; previously it was the `xor` of the two collections
* the list of remote files to delete (if that configuration option was specified) is now correctly calculated:
+ it is now simply the remote files minus the local files; previously it was the `cor` of the two collections

* new files are uploaded _before_ old files are deleted.