Add feature flag in setup for python support.

This commit is contained in:
Sander Declerck 2025-11-14 14:12:44 +01:00
parent 6b208a8730
commit c6bcd6f646
No known key found for this signature in database
13 changed files with 413 additions and 100 deletions

View file

@ -6,6 +6,7 @@ import fs from "fs";
import os from "os";
import path from "path";
import { fileURLToPath } from "url";
import { includePython } from "../config/cliArguments.js";
/**
* Loops over the detected shells and calls the setup function for each.
@ -104,7 +105,11 @@ function copyStartupFiles() {
// Use absolute path for source
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const sourcePath = path.resolve(__dirname, "startup-scripts", file);
const sourcePath = path.resolve(
__dirname,
includePython() ? "startup-scripts/include-python" : "startup-scripts",
file
);
fs.copyFileSync(sourcePath, targetPath);
}
}