Skip to content

Commit

Permalink
try this
Browse files Browse the repository at this point in the history
  • Loading branch information
jcbhmr authored Nov 14, 2023
1 parent d48ae1f commit c906278
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ are welcome! ❤️

- **`github-token`:** GitHub token to use for authentication when pulling and
pushing to the GitHub instance defined by `github-server-url`. By default this
uses `github.token`. Change this to a personal access token if you intend to
do things that go beyond the scope of the current repository.
is unset. You can set this to `github.token` or a personal access token if you
want to configure GitHub authentication globally.

- **`github-server-url`:** Server URL like `https://github.example.org` to use
as the scope for the `github-token`. By default this uses `github.server_url`
Expand Down
7 changes: 3 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@ inputs:
github-token:
description: >
GitHub token to use for authentication when pulling and pushing to the
GitHub instance defined by 'github-server-url'. By default this uses
'github.token'. Change this to a personal access token if you intend to do
things that go beyond the scope of the current repository.
default: ${{ github.token }}
GitHub instance defined by 'github-server-url'. By default this is unset.
You can set this to 'github.token' or a personal access token if you want
to configure GitHub authentication globally.
github-server-url:
description: >
Server URL like 'https://github.example.org' to use as the scope for the
Expand Down
2 changes: 1 addition & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ if (userName && userEmail) {
await $({ stdio: "inherit" })`git config --global user.email ${userEmail}`;
}

if (githubToken && githubServerURL) {
if (githubToken) {
const prefix = new URL(githubServerURL).origin + "/";
const basicAuth = Buffer.from(
`x-access-token:${githubToken}`,
Expand Down

0 comments on commit c906278

Please sign in to comment.