mirror of
https://github.com/tj/git-extras.git
synced 2026-09-10 07:26:17 -04:00
corrections
This commit is contained in:
parent
85e1c4ff0a
commit
238038139d
|
|
@ -39,11 +39,11 @@ fi
|
|||
test -z "$user" && abort "git config user.email required"
|
||||
|
||||
# personal access token
|
||||
# config name is personal-access-token '_' is not allowed in git config
|
||||
# config name is github-personal-access-token '_' is not allowed in git config
|
||||
|
||||
personal_access_token=$(git config git-extras.personal-access-token)
|
||||
github_personal_access_token=$(git config git-extras.github-personal-access-token)
|
||||
|
||||
test -z "$personal_access_token" && abort "git config git-extras.personal-access-token required"
|
||||
test -z "$github_personal_access_token" && abort "git config git-extras.github-personal-access-token required"
|
||||
|
||||
# branch
|
||||
|
||||
|
|
@ -90,7 +90,7 @@ body=$(json "$title" "$body" "$branch" "$base")
|
|||
curl \
|
||||
-X POST \
|
||||
-H "Accept: application/vnd.github.v3+json" \
|
||||
-H "Authorization: token $personal_access_token" \
|
||||
-H "Authorization: token $github_personal_access_token" \
|
||||
-H "X-GitHub-OTP: $mfa_code" \
|
||||
"https://api.github.com/repos/$project/pulls" -d "$body"
|
||||
|
||||
|
|
|
|||
|
|
@ -10,13 +10,13 @@ Create pull request for a project on GitHub via command line\.
|
|||
.P
|
||||
Uses the email from \fBgit config user\.email\fR to open the pull request\.
|
||||
.P
|
||||
Personal access token is required for making API call to open the pull request\.
|
||||
Personal access token is required for making API call to open the pull request in Github\.
|
||||
.P
|
||||
Makre sure the personal access token has the right \fBOAuth\fR scopes for the repo(s)
|
||||
Make sure the personal access token has the right \fBOAuth\fR scopes for the repo(s)
|
||||
.P
|
||||
use \fBgit config \-\-global \-\-add git\-extras\.personal\-access\-token <your\-personal\-access\-token>\fR
|
||||
Use \fBgit config \-\-global \-\-add git\-extras\.github\-personal\-access\-token <your\-personal\-access\-token>\fR
|
||||
.P
|
||||
if using mutiple accounts, override the global value in the specific repo using \fBgit config git\-extras\.personal\-access\-token <other\-acc\-personal\-access\-token>\fR
|
||||
If using mutiple accounts, override the global value in the specific repo using \fBgit config git\-extras\.github\-personal\-access\-token <other\-acc\-personal\-access\-token>\fR
|
||||
.SH "OPTIONS"
|
||||
<target branch>
|
||||
.P
|
||||
|
|
|
|||
|
|
@ -85,13 +85,13 @@
|
|||
|
||||
<p>Uses the email from <code>git config user.email</code> to open the pull request.</p>
|
||||
|
||||
<p>Personal access token is required for making API call to open the pull request.</p>
|
||||
<p>Personal access token is required for making API call to open the pull request in Github.</p>
|
||||
|
||||
<p>Makre sure the personal access token has the right <code>OAuth</code> scopes for the repo(s)</p>
|
||||
<p>Make sure the personal access token has the right <code>OAuth</code> scopes for the repo(s)</p>
|
||||
|
||||
<p>use <code>git config --global --add git-extras.personal-access-token <your-personal-access-token></code></p>
|
||||
<p>Use <code>git config --global --add git-extras.github-personal-access-token <your-personal-access-token></code></p>
|
||||
|
||||
<p>if using mutiple accounts, override the global value in the specific repo using <code>git config git-extras.personal-access-token <other-acc-personal-access-token></code></p>
|
||||
<p>If using mutiple accounts, override the global value in the specific repo using <code>git config git-extras.github-personal-access-token <other-acc-personal-access-token></code></p>
|
||||
|
||||
<h2 id="OPTIONS">OPTIONS</h2>
|
||||
|
||||
|
|
|
|||
|
|
@ -11,13 +11,13 @@ Create pull request for a project on GitHub via command line.
|
|||
|
||||
Uses the email from `git config user.email` to open the pull request.
|
||||
|
||||
Personal access token is required for making API call to open the pull request.
|
||||
Personal access token is required for making API call to open the pull request in Github.
|
||||
|
||||
Makre sure the personal access token has the right `OAuth` scopes for the repo(s)
|
||||
Make sure the personal access token has the right `OAuth` scopes for the repo(s)
|
||||
|
||||
use `git config --global --add git-extras.personal-access-token <your-personal-access-token>`
|
||||
Use `git config --global --add git-extras.github-personal-access-token <your-personal-access-token>`
|
||||
|
||||
if using mutiple accounts, override the global value in the specific repo using `git config git-extras.personal-access-token <other-acc-personal-access-token>`
|
||||
If using mutiple accounts, override the global value in the specific repo using `git config git-extras.github-personal-access-token <other-acc-personal-access-token>`
|
||||
|
||||
## OPTIONS
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue