mirror of
https://github.com/oven-sh/setup-bun.git
synced 2025-07-18 04:28:28 +02:00
feat: custom download url, custom repository
This commit is contained in:
parent
27a94d6f80
commit
e6a8865f72
9 changed files with 135 additions and 21 deletions
|
@ -15,11 +15,13 @@ const main = async() => {
|
|||
try {
|
||||
const version = getInput('bun-version');
|
||||
const token = getInput('github-token');
|
||||
const miscTestBuilds = (getInput('misc-test-builds') === 'true');
|
||||
const repository = getInput('repository');
|
||||
const miscTestBuilds = (getInput('misc-test-builds') === 'true') || (repository.includes('oven-sh/misc-test-builds'));
|
||||
const customDownloadUrl = getInput('custom-download-url') || null;
|
||||
|
||||
if (!version) return exit('Invalid bun version.');
|
||||
|
||||
const release = await getGithubRelease(version, token, miscTestBuilds);
|
||||
const release = await getGithubRelease(version, token, repository, customDownloadUrl, miscTestBuilds);
|
||||
if (release?.message === 'Not Found') return exit('Invalid bun version.', miscTestBuilds);
|
||||
|
||||
info(`Going to install release ${release.version}`);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue