perf: overlap context and repo metadata fetches

Signed-off-by: Zhiwei Liang <zhiwei.liang@zliang.me>
This commit is contained in:
Zhiwei Liang 2026-08-26 01:34:23 -04:00
parent 703896b4f3
commit 1ddc39e4af
No known key found for this signature in database

View file

@ -12,8 +12,10 @@ actionsToolkit.run(
async () => {
const inputs: Inputs = getInputs();
const toolkit = new Toolkit({githubToken: inputs.githubToken});
const context = await getContext(inputs.context, toolkit);
const repo = await toolkit.github.repoData();
const [context, repo] = await Promise.all([
getContext(inputs.context, toolkit),
toolkit.github.repoData()
]);
const setOutput = outputEnvEnabled() ? setOutputAndEnv : core.setOutput;
await core.group(`Context info`, async () => {