mirror of
https://github.com/actions/create-github-app-token.git
synced 2026-11-16 19:41:09 +00:00
The `repositories` input currently treats values like `${{
github.repository }}` as a repository name, which can produce a
duplicated owner in the installation lookup. This changes repository
target resolution so entries may be bare repository names or full
`owner/repository` names, while preserving the existing resolved owner
behavior.
Full repository names are accepted only when their owner matches the
`owner` input, or the current repository owner when `owner` is unset.
The action still creates a single installation token for one owner, and
generated `dist` artifacts are left unchanged for release.
Fixes: #177
---------
Co-authored-by: Copilot <[email protected]>
13 lines
450 B
JavaScript
13 lines
450 B
JavaScript
import { DEFAULT_ENV } from "./main.js";
|
|
|
|
// Verify `main` exits with an error when a repository entry is neither a repository name nor an owner/repository name.
|
|
for (const [key, value] of Object.entries(DEFAULT_ENV)) {
|
|
process.env[key] = value;
|
|
}
|
|
|
|
process.env.INPUT_OWNER = process.env.GITHUB_REPOSITORY_OWNER;
|
|
process.env.INPUT_REPOSITORIES = "octocat/hello-world/extra";
|
|
|
|
const { default: promise } = await import("../main.js");
|
|
await promise;
|
|
|