mirror of
https://github.com/AikidoSec/safe-chain.git
synced 2026-05-26 12:10:49 +00:00
Another iteration
This commit is contained in:
parent
f400c5576a
commit
28d24bb6ea
12 changed files with 134 additions and 107 deletions
|
|
@ -1,19 +1,19 @@
|
|||
#!/usr/bin/env node
|
||||
|
||||
|
||||
import { main } from "../src/main.js";
|
||||
import { initializePackageManager } from "../src/packagemanager/currentPackageManager.js";
|
||||
import { setEcoSystem, ECOSYSTEM_PY } from "../src/config/settings.js";
|
||||
|
||||
// Defaults
|
||||
let packageManagerName = "pip";
|
||||
// Pass through user args as-is
|
||||
const argv = process.argv.slice(2);
|
||||
import { setCurrentPipInvocation, PIP_INVOCATIONS, PIP_PACKAGE_MANAGER } from "../src/packagemanager/pip/pipSettings.js";
|
||||
|
||||
// Set eco system
|
||||
// This can be used in other parts of the code to determine which eco system we are working with
|
||||
setEcoSystem(ECOSYSTEM_PY);
|
||||
|
||||
initializePackageManager(packageManagerName);
|
||||
var exitCode = await main(argv);
|
||||
// Set current invocation
|
||||
setCurrentPipInvocation(PIP_INVOCATIONS.PIP);
|
||||
|
||||
initializePackageManager(PIP_PACKAGE_MANAGER);
|
||||
|
||||
// Pass through only user-supplied pip args
|
||||
var exitCode = await main(process.argv.slice(2));
|
||||
process.exit(exitCode);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue