Adds ReleaseChanges object to stage changes to S3 during CI runs.

- Also allows merging of those changes.
- Removes the final option from the creating a release
  (all releases are currently final).

Signed-off-by: Jesse Zhang <jz@pivotallabs.com>
Publishing a release now stages changes to S3.

Refactors the guts of the publish bosh release rake task into an object for testability

Signed-off-by: Jesse Zhang <jz@pivotallabs.com>
correct a method description in test

Signed-off-by: Jesse Zhang <jz@pivotallabs.com>
Splits ReleaseCreator and ReleaseChanges out into separate files.

- also makes rubocop happy

Signed-off-by: Jesse Zhang <jz@pivotallabs.com>
Replace HEAD with candidate sha

The HEAD will no longer point to the candidate SHA after our next
commit.

Signed-off-by: Jesse Zhang <jz@pivotallabs.com>
wrap tests in describe

now that we are about to have a second method...

Signed-off-by: Mike Stallard <mstallard@pivotallabs.com>
factory method to construct the Promoter

- This commit also changes the constructor to use positional arguments.
- logger is now injected
rename ReleaseChanges to ReleaseChangeStager

something else should be responsible for promoting the final release
introduce ReleaseChangePromoter

Signed-off-by: Matthew Boedicker <mboedicker@pivotallabs.com>
Make downloaded patch s3 key empty to match upload key.

Signed-off-by: Matthew Boedicker <mboedicker@pivotallabs.com>
Use real build number in tempfile prefix.

Signed-off-by: Matthew Boedicker <mboedicker@pivotallabs.com>
Make Bosh::Dev::Promoter commit final release.

Signed-off-by: Matthew Boedicker <mboedicker@pivotallabs.com>
git add after applying patch.

Signed-off-by: Matthew Boedicker <mboedicker@pivotallabs.com>
Don't add double slash when remote_directory_path is empty.

Signed-off-by: Matthew Boedicker <mboedicker@pivotallabs.com>
Fix rubocop offences.

[Finishes #58382172].

Signed-off-by: Matthew Boedicker <mboedicker@pivotallabs.com>