Skip to content

Commit c5e9288

Browse files
committed
homebrew fix
1 parent 1767513 commit c5e9288

File tree

2 files changed

+32
-32
lines changed

2 files changed

+32
-32
lines changed

dist/index.js

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6762,39 +6762,39 @@ const urls = {
67626762

67636763
async function downloadCLI(osPlatform) {
67646764
try {
6765-
core.info(`Preparing to download/install stackql for ${osPlatform}`);
6765+
core.info(`preparing to download/install stackql for ${osPlatform}`);
67666766

67676767
switch (osPlatform) {
67686768
case 'win32':
67696769
return await tc.extractZip(await tc.downloadTool(urls[osPlatform]));
67706770
case 'darwin':
67716771
// Check if stackql is already installed using brew list --formula
6772-
core.info(`Checking if stackql is already installed`);
6772+
core.info(`checking if stackql is already installed...`);
67736773
try {
67746774
const installedFormulas = execSync('brew list --formula', { encoding: 'utf-8' });
67756775
if (installedFormulas.includes('stackql')) {
67766776
core.info(`stackql is already installed.`);
67776777
const stackqlPath = execSync('which stackql', { encoding: 'utf-8' }).trim();
6778-
core.debug(`Stackql is located at: ${stackqlPath}`);
6778+
core.debug(`stackql is located at: ${stackqlPath}`);
67796779
return path.dirname(stackqlPath); // Return the directory of the binary
67806780
} else {
6781-
core.info(`Installing stackql using Homebrew`);
6781+
core.info(`installing stackql using Homebrew...`);
67826782
execSync('brew install stackql', { stdio: 'inherit' });
67836783
}
67846784
} catch (error) {
6785-
core.info(`Error checking/installing stackql: ${error}`);
6786-
throw new Error(`Error checking/installing stackql: ${error}`);
6785+
core.info(`error checking/installing stackql: ${error}`);
6786+
throw new Error(`error checking/installing stackql: ${error}`);
67876787
}
67886788
const installedPath = execSync('which stackql', { encoding: 'utf-8' }).trim();
6789-
core.debug(`Stackql installed at: ${installedPath}`);
6789+
core.debug(`stackql installed at: ${installedPath}`);
67906790
return path.dirname(installedPath); // Return the directory of the binary
67916791
case 'linux':
67926792
return await tc.extractZip(await tc.downloadTool(urls[osPlatform]));
67936793
default:
6794-
throw new Error(`Unsupported platform: ${osPlatform}`);
6794+
throw new Error(`unsupported platform: ${osPlatform}`);
67956795
}
67966796
} catch (error) {
6797-
core.error(`Failed to install Stackql: ${error}`);
6797+
core.error(`failed to install stackql: ${error}`);
67986798
throw error;
67996799
}
68006800
}
@@ -6823,21 +6823,21 @@ async function installWrapper (pathToCLI) {
68236823
try {
68246824
source = [pathToCLI, `stackql${exeSuffix}`].join(path.sep);
68256825
target = [pathToCLI, `stackql-bin${exeSuffix}`].join(path.sep);
6826-
core.debug(`Moving ${source} to ${target}.`);
6826+
core.debug(`moving ${source} to ${target}...`);
68276827
await io.mv(source, target);
68286828
} catch (e) {
6829-
core.debug(`Unable to move ${source} to ${target}.`);
6829+
core.debug(`unable to move ${source} to ${target}.`);
68306830
throw e;
68316831
}
68326832

68336833
// Install our wrapper as stackql by moving the wrapped executable to stackql
68346834
try {
68356835
source = path.resolve([__dirname, '..', 'wrapper', 'dist', 'index.js'].join(path.sep));
68366836
target = [pathToCLI, 'stackql'].join(path.sep);
6837-
core.debug(`Copying ${source} to ${target}.`);
6837+
core.debug(`copying ${source} to ${target}...`);
68386838
await io.cp(source, target);
68396839
} catch (e) {
6840-
core.error(`Unable to copy ${source} to ${target}.`);
6840+
core.error(`unable to copy ${source} to ${target}.`);
68416841
throw e;
68426842
}
68436843

@@ -6862,17 +6862,17 @@ async function setup() {
68626862

68636863
// set perms and make executable
68646864
if(osPlatform != 'darwin'){
6865-
core.debug(`updating permissions for ${cliPath}`);
6865+
core.debug(`updating permissions for ${cliPath}...`);
68666866
fs.chmodSync(cliPath, '777');
6867-
core.debug(`adding ${cliPath} to the path`);
6867+
core.debug(`adding ${cliPath} to the path...`);
68686868
core.addPath(cliPath)
68696869
await makeExecutable(cliPath, osPlatform)
68706870
}
68716871

68726872
const wrapper = core.getInput('use_wrapper') === 'true';
68736873

68746874
if(wrapper){
6875-
core.info('installing wrapper')
6875+
core.info('installing wrapper...')
68766876
await installWrapper(cliPath)
68776877
}
68786878
core.info(`successfully setup stackql at ${cliPath}`);

index.js

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -13,39 +13,39 @@ const urls = {
1313

1414
async function downloadCLI(osPlatform) {
1515
try {
16-
core.info(`Preparing to download/install stackql for ${osPlatform}`);
16+
core.info(`preparing to download/install stackql for ${osPlatform}`);
1717

1818
switch (osPlatform) {
1919
case 'win32':
2020
return await tc.extractZip(await tc.downloadTool(urls[osPlatform]));
2121
case 'darwin':
2222
// Check if stackql is already installed using brew list --formula
23-
core.info(`Checking if stackql is already installed`);
23+
core.info(`checking if stackql is already installed...`);
2424
try {
2525
const installedFormulas = execSync('brew list --formula', { encoding: 'utf-8' });
2626
if (installedFormulas.includes('stackql')) {
2727
core.info(`stackql is already installed.`);
2828
const stackqlPath = execSync('which stackql', { encoding: 'utf-8' }).trim();
29-
core.debug(`Stackql is located at: ${stackqlPath}`);
29+
core.debug(`stackql is located at: ${stackqlPath}`);
3030
return path.dirname(stackqlPath); // Return the directory of the binary
3131
} else {
32-
core.info(`Installing stackql using Homebrew`);
32+
core.info(`installing stackql using Homebrew...`);
3333
execSync('brew install stackql', { stdio: 'inherit' });
3434
}
3535
} catch (error) {
36-
core.info(`Error checking/installing stackql: ${error}`);
37-
throw new Error(`Error checking/installing stackql: ${error}`);
36+
core.info(`error checking/installing stackql: ${error}`);
37+
throw new Error(`error checking/installing stackql: ${error}`);
3838
}
3939
const installedPath = execSync('which stackql', { encoding: 'utf-8' }).trim();
40-
core.debug(`Stackql installed at: ${installedPath}`);
40+
core.debug(`stackql installed at: ${installedPath}`);
4141
return path.dirname(installedPath); // Return the directory of the binary
4242
case 'linux':
4343
return await tc.extractZip(await tc.downloadTool(urls[osPlatform]));
4444
default:
45-
throw new Error(`Unsupported platform: ${osPlatform}`);
45+
throw new Error(`unsupported platform: ${osPlatform}`);
4646
}
4747
} catch (error) {
48-
core.error(`Failed to install Stackql: ${error}`);
48+
core.error(`failed to install stackql: ${error}`);
4949
throw error;
5050
}
5151
}
@@ -74,21 +74,21 @@ async function installWrapper (pathToCLI) {
7474
try {
7575
source = [pathToCLI, `stackql${exeSuffix}`].join(path.sep);
7676
target = [pathToCLI, `stackql-bin${exeSuffix}`].join(path.sep);
77-
core.debug(`Moving ${source} to ${target}.`);
77+
core.debug(`moving ${source} to ${target}...`);
7878
await io.mv(source, target);
7979
} catch (e) {
80-
core.debug(`Unable to move ${source} to ${target}.`);
80+
core.debug(`unable to move ${source} to ${target}.`);
8181
throw e;
8282
}
8383

8484
// Install our wrapper as stackql by moving the wrapped executable to stackql
8585
try {
8686
source = path.resolve([__dirname, '..', 'wrapper', 'dist', 'index.js'].join(path.sep));
8787
target = [pathToCLI, 'stackql'].join(path.sep);
88-
core.debug(`Copying ${source} to ${target}.`);
88+
core.debug(`copying ${source} to ${target}...`);
8989
await io.cp(source, target);
9090
} catch (e) {
91-
core.error(`Unable to copy ${source} to ${target}.`);
91+
core.error(`unable to copy ${source} to ${target}.`);
9292
throw e;
9393
}
9494

@@ -113,17 +113,17 @@ async function setup() {
113113

114114
// set perms and make executable
115115
if(osPlatform != 'darwin'){
116-
core.debug(`updating permissions for ${cliPath}`);
116+
core.debug(`updating permissions for ${cliPath}...`);
117117
fs.chmodSync(cliPath, '777');
118-
core.debug(`adding ${cliPath} to the path`);
118+
core.debug(`adding ${cliPath} to the path...`);
119119
core.addPath(cliPath)
120120
await makeExecutable(cliPath, osPlatform)
121121
}
122122

123123
const wrapper = core.getInput('use_wrapper') === 'true';
124124

125125
if(wrapper){
126-
core.info('installing wrapper')
126+
core.info('installing wrapper...')
127127
await installWrapper(cliPath)
128128
}
129129
core.info(`successfully setup stackql at ${cliPath}`);

0 commit comments

Comments
 (0)