chore: build & remove debug
This commit is contained in:
7
dist/utils/install.js
vendored
7
dist/utils/install.js
vendored
@@ -3,7 +3,6 @@ import { addPath, info } from '@actions/core';
|
||||
import getAsset from './getAsset.js';
|
||||
import getHomeDir from './getHomeDir.js';
|
||||
import { join } from 'path';
|
||||
import { readdirSync } from 'fs';
|
||||
export default async (release) => {
|
||||
const cache = find('bun', release.tag_name);
|
||||
if (cache) {
|
||||
@@ -14,12 +13,10 @@ export default async (release) => {
|
||||
const asset = getAsset(release.assets);
|
||||
info(`Downloading Bun from ${asset.asset.browser_download_url}.`);
|
||||
const zipPath = await downloadTool(asset.asset.browser_download_url);
|
||||
const extracted = await extractZip(zipPath, join(getHomeDir(), ".bun", "bin"));
|
||||
const extracted = await extractZip(zipPath, join(getHomeDir(), '.bun', 'bin'));
|
||||
const newCache = await cacheDir(extracted, 'bun', release.tag_name);
|
||||
info(`Cached Bun to ${newCache}.`);
|
||||
addPath(newCache);
|
||||
console.log(extracted);
|
||||
const bunPath = join(getHomeDir(), ".bun", "bin", asset.name.replace('.zip', ''));
|
||||
console.log(readdirSync(bunPath));
|
||||
const bunPath = join(getHomeDir(), '.bun', 'bin', asset.name.replace('.zip', ''));
|
||||
addPath(bunPath);
|
||||
};
|
||||
|
||||
@@ -4,7 +4,6 @@ import { addPath, info } from '@actions/core';
|
||||
import getAsset from './getAsset.js';
|
||||
import getHomeDir from './getHomeDir.js';
|
||||
import { join } from 'path';
|
||||
import { readdirSync } from 'fs';
|
||||
|
||||
export default async(release: Release) => {
|
||||
const cache = find('bun', release.tag_name);
|
||||
@@ -19,7 +18,7 @@ export default async(release: Release) => {
|
||||
info(`Downloading Bun from ${asset.asset.browser_download_url}.`);
|
||||
|
||||
const zipPath = await downloadTool(asset.asset.browser_download_url);
|
||||
const extracted = await extractZip(zipPath, join(getHomeDir(), ".bun", "bin"));
|
||||
const extracted = await extractZip(zipPath, join(getHomeDir(), '.bun', 'bin'));
|
||||
|
||||
const newCache = await cacheDir(
|
||||
extracted,
|
||||
@@ -30,8 +29,6 @@ export default async(release: Release) => {
|
||||
info(`Cached Bun to ${newCache}.`);
|
||||
addPath(newCache);
|
||||
|
||||
console.log(extracted);
|
||||
const bunPath = join(getHomeDir(), ".bun", "bin", asset.name.replace('.zip', ''));
|
||||
console.log(readdirSync(bunPath));
|
||||
const bunPath = join(getHomeDir(), '.bun', 'bin', asset.name.replace('.zip', ''));
|
||||
addPath(bunPath);
|
||||
}
|
||||
Reference in New Issue
Block a user