Skip to content

Commit d1e04fc

Browse files
authored
Merge pull request #299 from isuruf/condaBasePath
2 parents fab0073 + fa6bdf9 commit d1e04fc

File tree

2 files changed

+11
-15
lines changed

2 files changed

+11
-15
lines changed

Diff for: dist/setup/index.js

+6-8
Original file line numberDiff line numberDiff line change
@@ -47248,14 +47248,12 @@ const utils = __importStar(__nccwpck_require__(1314));
4724847248
* Provide current location of miniconda or location where it will be installed
4724947249
*/
4725047250
function condaBasePath(options) {
47251-
let condaPath = constants.MINICONDA_DIR_PATH;
47252-
if (!options.useBundled) {
47253-
if (constants.IS_MAC) {
47254-
condaPath = "/Users/runner/miniconda3";
47255-
}
47256-
else {
47257-
condaPath += "3";
47258-
}
47251+
let condaPath;
47252+
if (options.useBundled) {
47253+
condaPath = constants.MINICONDA_DIR_PATH;
47254+
}
47255+
else {
47256+
condaPath = path.join(os.homedir(), "miniconda3");
4725947257
}
4726047258
return condaPath;
4726147259
}

Diff for: src/conda.ts

+5-7
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,11 @@ import * as utils from "./utils";
1717
* Provide current location of miniconda or location where it will be installed
1818
*/
1919
export function condaBasePath(options: types.IDynamicOptions): string {
20-
let condaPath: string = constants.MINICONDA_DIR_PATH;
21-
if (!options.useBundled) {
22-
if (constants.IS_MAC) {
23-
condaPath = "/Users/runner/miniconda3";
24-
} else {
25-
condaPath += "3";
26-
}
20+
let condaPath: string;
21+
if (options.useBundled) {
22+
condaPath = constants.MINICONDA_DIR_PATH;
23+
} else {
24+
condaPath = path.join(os.homedir(), "miniconda3");
2725
}
2826
return condaPath;
2927
}

0 commit comments

Comments
 (0)