mirror of
https://github.com/AikidoSec/safe-chain.git
synced 2026-05-26 20:20:49 +00:00
Some more cleanup
This commit is contained in:
parent
ccd595fc22
commit
98dcda78da
5 changed files with 40 additions and 94 deletions
|
|
@ -141,9 +141,10 @@ function cygpathw(path) {
|
|||
}
|
||||
}
|
||||
|
||||
function getManualTeardownInstructions() {
|
||||
/** @param {string} preamble */
|
||||
function buildManualInstructions(preamble) {
|
||||
const customDir = getSafeChainDir();
|
||||
const instructions = [`Remove the following line from your ~/.bashrc file:`];
|
||||
const instructions = [preamble];
|
||||
|
||||
if (customDir) {
|
||||
instructions.push(
|
||||
|
|
@ -158,21 +159,12 @@ function getManualTeardownInstructions() {
|
|||
return instructions;
|
||||
}
|
||||
|
||||
function getManualTeardownInstructions() {
|
||||
return buildManualInstructions(`Remove the following line from your ~/.bashrc file:`);
|
||||
}
|
||||
|
||||
function getManualSetupInstructions() {
|
||||
const customDir = getSafeChainDir();
|
||||
const instructions = [`Add the following line to your ~/.bashrc file:`];
|
||||
|
||||
if (customDir) {
|
||||
instructions.push(
|
||||
` export SAFE_CHAIN_DIR="${customDir}"`,
|
||||
` source ${path.join(getScriptsDir(), "init-posix.sh")}`,
|
||||
);
|
||||
} else {
|
||||
instructions.push(` source ~/.safe-chain/scripts/init-posix.sh`);
|
||||
}
|
||||
|
||||
instructions.push(`Then restart your terminal or run: source ~/.bashrc`);
|
||||
return instructions;
|
||||
return buildManualInstructions(`Add the following line to your ~/.bashrc file:`);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue