magit-with-git-editor-setup: respect server-socket-dir
add option magit-git-editor

This changes `magit-with-git-editor-setup's default behaviour:
If $GIT_EDITOR is set and contains the substring "emacsclient"
then that is used.  If the former is unset try $EDITOR instead.
Only if that fails fallback to the old default behaviour of
setting $GIT_EDITOR temporarly (and even if the user has
also configured it explicitly).
Merge branch 'hotfix'