elfet/deployer — pull request #51 by jelte (2014-08-07 19:07:20+00:00)
Title: [WIP] Bugfix dry-run

**note: Already made this pull-request as it hold significant refactoring and wanted to share and get some opinions**

# Bugs
- [x] dry-run option doesn't share env() #45
- [x] dry-run option still executes runLocally & upload commands #46

# LocalInterface & Local
Introduction of a Local system concept was needed to be able to replace the actions. Local works much like Server but doesn't connect, has an environment or config.

By default a Local will be created and managed by the Deployer instance.

# Environment
Environment doesn't hold the current environment anymore instead Runner has its current ServerInterface and LocalInterface.
It makes more sense to remember the current server than the current environment. Shortcut to the environment still exists.
The Environment does not know which server it belongs to, it is just a container for parameters

# Runner
Now holds the current server and local. (These are static for now goal is to have the Deployer govern these.)

# getReleases & get/setReleasePath moved to AbstractServer
As the Environment is just a parameter container, I moved these methods to AbstractServer, which also makes more sense in my opinion.

# Renamed DryRun to DryRunServer
with the introduction of DryRunLocal, it is better to have distinctive names.

# functions
Changed many of the functions to support the new setup, but retained their functionality.

## runLocally
now uses the Local instance, which can be a DryRunLocal

## upload
move body of the function to Local so it can be replaced by DryRunLocal.

# Tests
As there are hardly any existing test for these functionalities, it will take some time to get everything properly tested.