Skip to content

Commit cffd6fb

Browse files
refactor: use github-api-url-public
1 parent 2f8e607 commit cffd6fb

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ Action returns some basic information. For more details, follow [📤 Outputs](#
8080
| `pyflakes` | false | `bool` | `true` | Use `pyflakes` with `actionlint` (and install if it does not exist) |
8181
| `cache` | false | `bool` | `true` | Use GitHub cache for caching binaries for the next runs. |
8282
| `github-token` | false | `string` | `github.token` | GitHub Token for API authentication. |
83-
| `github-api-url` | false | `string` | `github.api_url` | GitHub REST API URL to connect to a different GitHub instance. For example, `https://my.github-enterprise-server.com/api/v3` |
83+
| `github-api-url-public` | false | `string` | `github.api_url` | Public GitHub REST API URL to connect to for dependencies download. For example, `https://api.github.com`. Required if you are running in the GHES. |
8484

8585
## 📤 Outputs
8686

action.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ inputs:
6262
description: GitHub Token
6363
required: false
6464
default: ${{ github.token }}
65-
github-api-url:
66-
description: GitHub REST API URL
65+
github-api-url-public:
66+
description: Public GitHub REST API URL for dependencies download
6767
required: false
6868
default: ${{ github.api_url }}
6969
outputs:
@@ -217,8 +217,8 @@ runs:
217217
uses: actions/github-script@v7
218218
if: ${{ steps.tool-cache.outputs.cache-hit != 'true' }}
219219
with:
220-
github-token: ${{ inputs.github-token || inputs.token || env.GITHUB_TOKEN }}
221-
base-url: ${{ inputs.github-api-url }}
220+
# github-token: ${{ inputs.github-token || inputs.token || env.GITHUB_TOKEN }}
221+
base-url: ${{ inputs.github-api-url-public }}
222222
script: |
223223
// dependencies
224224
const tc = require('@actions/tool-cache')
@@ -256,7 +256,7 @@ runs:
256256
id: tool-dependencies
257257
with:
258258
github-token: ${{ inputs.github-token || inputs.token || env.GITHUB_TOKEN }}
259-
base-url: ${{ inputs.github-api-url }}
259+
# base-url: ${{ inputs.github-api-url }}
260260
script: |
261261
// input envs
262262
const { INPUT_PYFLAKES, INPUT_SHELLCHECK } = process.env
@@ -322,7 +322,7 @@ runs:
322322
id: tool-runner
323323
with:
324324
github-token: ${{ inputs.github-token || inputs.token || env.GITHUB_TOKEN }}
325-
base-url: ${{ inputs.github-api-url }}
325+
# base-url: ${{ inputs.github-api-url }}
326326
script: |
327327
// input envs
328328
const { INPUT_FILES, INPUT_FLAGS, INPUT_TOOL_NAME, INPUT_TOOL_DIR_PATH, INPUT_MATCHER, INPUT_MATCHER_PATH, INPUT_TOOL_EXECUTABLE, INPUT_JSON, INPUT_FAIL_ON_ERROR, INPUT_PYFLAKES, INPUT_SHELLCHECK, INPUT_GROUP_RESULT, DEBUG } = process.env

0 commit comments

Comments
 (0)