Save opam file back to the source when pin-editing path-pinned packages

after user confirmation. Should also help packagers getting started.
Add an opam 'dev-repo' field to hold the upstream source URL

this should be a valid VC pinning target, i.e. git, darcs or hg URL.
Add pinning options

* --dev-repo will select automatically the upstream target (granted it's filled in the metadata)
* Install after pinning and reinstall after unpinning (if still available) by default. Provide
  --no-action to just set the pin and nothing else
Small fix for explicit upgrade of orphan package

previously 'opam upgrade XX' wouldn't ask for downgrade when the installed version
is no longer available, while 'opam upgrade' without argument would
Fix check for empty opam metadata

was causing OPAM to always trigger the editor at pinning. It
should only be fired when '-e' or no opam is found
Merge pull request #1442 from OCamlPro/pin-improvements

Defining the dev workflow, adding pin commands, and small fixes