stream package to new repo ☺️
All checks were successful
Distribution check / Generated files check (push) Successful in -2m1s
NPM Audit Check / Check NPM audit (push) Successful in -2m10s
Unit tests / Unit tests (latest) (push) Successful in -2m1s
Unit tests / Unit tests (lts/*) (push) Successful in -2m0s
Unit tests / Unit tests (lts/hydrogen) (push) Successful in -2m0s

This commit is contained in:
2025-11-06 23:29:40 -05:00
parent e2e5a99d85
commit 6c1e088d7f
3 changed files with 11 additions and 3 deletions

View File

@@ -24,7 +24,11 @@ async function main() {
throw new Error(`Expected one matching package, found ${match.length}`); throw new Error(`Expected one matching package, found ${match.length}`);
} }
const packageUrl = `${context.serverUrl}/${context.repo.owner}/-/packages/arch/${pkg.package}/${pkg.version}/files/${match[0].id}`; const packageUrl = `${context.serverUrl}/${context.repo.owner}/-/packages/arch/${pkg.package}/${pkg.version}/files/${match[0].id}`;
// const req = (await ky.get(packageUrl)).body.pipeThrough; const { body } = await ky.get(packageUrl);
await ky.put(`${context.serverUrl}/api/packages/${context.repo.owner}/arch/${parsedData.actions.addRepo}`, {
body,
headers
});
} }
parsedData.delete.push(...parsedData.move); parsedData.delete.push(...parsedData.move);
} }

File diff suppressed because one or more lines are too long

View File

@@ -37,7 +37,11 @@ async function main() {
throw new Error(`Expected one matching package, found ${match.length}`); throw new Error(`Expected one matching package, found ${match.length}`);
} }
const packageUrl = `${context.serverUrl}/${context.repo.owner}/-/packages/arch/${pkg.package}/${pkg.version}/files/${match[0].id}`; const packageUrl = `${context.serverUrl}/${context.repo.owner}/-/packages/arch/${pkg.package}/${pkg.version}/files/${match[0].id}`;
// const req = (await ky.get(packageUrl)).body.pipeThrough; const { body } = await ky.get(packageUrl);
await ky.put(`${context.serverUrl}/api/packages/${context.repo.owner}/arch/${parsedData.actions.addRepo}`, {
body,
headers
});
} }
parsedData.delete.push(...parsedData.move); parsedData.delete.push(...parsedData.move);
} }