cf-upgrade's exit code should indicate successful installation or failure.
Failure should be returned when install didn't take place and restoration of old version was successful.
Code deduplication.
Write more to the console.
Globals with capital letters.
Make cf-upgrade more verbose by default.
Merge pull request #1809 from jimis/cfupgrade

cf-upgrade sanitisation