sociomantic/git-hub — pull request #99 by leandro-lucarella-sociomantic (2014-07-24 14:39:49+00:00)
Title: Setup is not allowed if a personal access token already exists

Currently there is no way for the same user to set up git-hub on two separate systems, as the second attempt to use `git hub setup` (on a different machine) will always fail.

In order to set up git-hub on a different system, the personal access token needs to be manually deleted in `Account settings -> Applications` on the GitHub website.

terminal output:
```
$> git hub -v setup
git command: ['git', 'config', 'hub.username'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.oauthtoken'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.upstream'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.forkrepo'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.forkremote'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.pullbase'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.urltype'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.baseurl'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', '--bool', 'hub.forcerebase'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', '--bool', 'hub.triangular'] {'stderr': -1, 'stdout': -1}
git command: ['git', 'config', 'hub.password'] {'stderr': -1, 'stdout': -1}
GitHub username [gautam]: gautam-kotian-sociomantic
GitHub password (will not be stored):
Request: POST https://api.github.com/authorizations
{"note": "git-hub", "scopes": ["user", "repo"]}
https://api.github.com/authorizations
Content-length: 47
Content-type: application/json
Authorization:
Accept: application/vnd.github.beta+json
{"note": "git-hub", "scopes": ["user", "repo"]}
Error: GitHub error: Validation Failed
Error: HTTP Error 422: Unprocessable Entity
Error: https://api.github.com/authorizations
Error:
Error: {"message":"Validation Failed","documentation_url":"https://developer.github.com/v3/oauth_authorizations/#create-a-new-authorization","errors":[{"resource":"OauthAccess","code":"already_exists","field":"description"}]}
$>
```