mirror of
https://github.com/nahuhh/basicswap-bash.git
synced 2024-12-22 19:49:21 +00:00
Compare commits
No commits in common. "e7e55e74ed4ca153b8f3b656b9f5affa7dd669e8" and "e2a574cf9b3fce4fd75610684d857bebf008f530" have entirely different histories.
e7e55e74ed
...
e2a574cf9b
14 changed files with 146 additions and 172 deletions
10
bsx-addcoin
10
bsx-addcoin
|
@ -2,15 +2,15 @@
|
|||
export SWAP_DATADIR=$HOME/coinswaps
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Check if basicswap is running
|
||||
if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
||||
bsx_pid=$(cat $SWAP_DATADIR/particl/particl.pid)
|
||||
if [[ $bsx_pid ]]; then
|
||||
bsx_run=$(pgrep particld | grep $bsx_pid)
|
||||
bsx_run=$(pidof particld | grep $bsx_pid)
|
||||
if [[ $bsx_run ]]; then
|
||||
$red"\nError: BasicSwapDEX is running.\n"; $nocolor
|
||||
exit
|
||||
|
@ -18,7 +18,7 @@ if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
printf "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n\n"
|
||||
echo -e "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n"
|
||||
until [[ "$l" =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option [1|2]: ' l
|
||||
case $l in
|
||||
|
|
|
@ -2,15 +2,15 @@
|
|||
export SWAP_DATADIR=$HOME/coinswaps
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Check if basicswap is running
|
||||
if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
||||
bsx_pid=$(cat $SWAP_DATADIR/particl/particl.pid)
|
||||
if [[ $bsx_pid ]]; then
|
||||
bsx_run=$(pgrep particld | grep $bsx_pid)
|
||||
bsx_run=$(pidof particld | grep $bsx_pid)
|
||||
if [[ $bsx_run ]]; then
|
||||
$red"\nError: BasicSwapDEX is running.\n"; $nocolor
|
||||
exit
|
||||
|
@ -18,7 +18,7 @@ if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
printf "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n\n"
|
||||
echo -e "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n"
|
||||
until [[ "$l" =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option [1|2]: ' l
|
||||
case $l in
|
||||
|
|
|
@ -2,15 +2,15 @@
|
|||
export SWAP_DATADIR=$HOME/coinswaps
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Check if basicswap is running
|
||||
if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
||||
bsx_pid=$(cat $SWAP_DATADIR/particl/particl.pid)
|
||||
if [[ $bsx_pid ]]; then
|
||||
bsx_run=$(pgrep particld | grep $bsx_pid)
|
||||
bsx_run=$(pidof particld | grep $bsx_pid)
|
||||
if [[ $bsx_run ]]; then
|
||||
$red"\nError: BasicSwapDEX is running.\n"; $nocolor
|
||||
exit
|
||||
|
@ -18,7 +18,7 @@ if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
printf "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n\n"
|
||||
echo -e "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n"
|
||||
until [[ "$l" =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option [1|2]: ' l
|
||||
case $l in
|
||||
|
|
|
@ -2,14 +2,14 @@
|
|||
export SWAP_DATADIR=$HOME/coinswaps
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Check if basicswap is running
|
||||
if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
||||
bsx_pid=$(cat $SWAP_DATADIR/particl/particl.pid)
|
||||
bsx_run=$(pgrep particld | grep $bsx_pid)
|
||||
bsx_run=$(pidof particld | grep $bsx_pid)
|
||||
if ! [[ $bsx_run ]]; then
|
||||
$red"\nError: BasicSwapDEX must be running.\n"; $nocolor
|
||||
exit
|
||||
|
@ -19,7 +19,7 @@ else
|
|||
exit
|
||||
fi
|
||||
|
||||
cp $HOME/.local/bin/bsx/placeorders/* $SWAP_DATADIR/basicswap/scripts/.
|
||||
mv $HOME/.local/bin/bsx/placeorders/* $SWAP_DATADIR/basicswap/scripts/
|
||||
cd $SWAP_DATADIR/basicswap/scripts/
|
||||
|
||||
./placeorders.sh
|
||||
|
|
|
@ -2,15 +2,15 @@
|
|||
export SWAP_DATADIR=$HOME/coinswaps
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Check if basicswap is running
|
||||
if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
||||
bsx_pid=$(cat $SWAP_DATADIR/particl/particl.pid)
|
||||
if [[ $bsx_pid ]]; then
|
||||
bsx_run=$(pgrep particld | grep $bsx_pid)
|
||||
bsx_run=$(pidof particld | grep $bsx_pid)
|
||||
if [[ $bsx_run ]]; then
|
||||
$red"\nError: BasicSwapDEX is running.\n"; $nocolor
|
||||
exit
|
||||
|
@ -18,7 +18,7 @@ if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
printf "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n\n"
|
||||
echo -e "BasicSwapDEX is currently:\n[1] Password protected\n[2] NOT password protected\n"
|
||||
until [[ "$l" =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option [1|2]: ' l
|
||||
case $l in
|
||||
|
|
|
@ -2,15 +2,15 @@
|
|||
export SWAP_DATADIR=$HOME/coinswaps
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Check if basicswap is running
|
||||
if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
||||
bsx_pid=$(cat $SWAP_DATADIR/particl/particl.pid)
|
||||
if [[ $bsx_pid ]]; then
|
||||
bsx_run=$(pgrep particld | grep $bsx_pid)
|
||||
bsx_run=$(pidof particld | grep $bsx_pid)
|
||||
if [[ $bsx_run ]]; then
|
||||
$red"\nError: BasicSwapDEX is running.\n"; $nocolor
|
||||
exit
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
## Prompt for user input
|
||||
printf "\n\nThe following coins can be added (case sensitive)\nbitcoin\ndash\ndecred\nfiro\nlitecoin\npivx\nwownero\n\n"
|
||||
echo -e "\n\nThe following coins can be added (case sensitive)\nbitcoin\ndash\ndecred\nfiro\nlitecoin\npivx\nwownero\n"
|
||||
read -p 'Full name of coin to add [example: litecoin] ' addcoin
|
||||
## Confirm
|
||||
read -p $'\nAdd '$addcoin' to your BasicSwap install, correct? Press ENTER to continue. CTRL-C to exit'
|
||||
|
|
|
@ -1,58 +1,36 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Detect Operating system
|
||||
INSTALL=""
|
||||
UPDATE=""
|
||||
INIT_TOR=""
|
||||
SYSTEMD_TOR="sudo systemctl restart tor"
|
||||
|
||||
check_tails() {
|
||||
if [[ $USER == amnesia ]]; then
|
||||
$green"\n\nDetected Tails";$nocolor
|
||||
TAILS=1
|
||||
else
|
||||
$green"\n\nDetected Debian";$nocolor
|
||||
fi
|
||||
}
|
||||
|
||||
INIT_TOR="sudo systemctl restart tor"
|
||||
detect_os_arch() {
|
||||
if [[ $(uname -s) = "Darwin" ]]; then
|
||||
# MacOS
|
||||
export MACOS=1
|
||||
if type -p brew > /dev/null; then
|
||||
$green"Homebrew is installed\n";$nc
|
||||
INSTALL="brew install"
|
||||
else
|
||||
$green"Installing Homebrew\n";$nc
|
||||
INSTALL="curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh | /bin/bash && brew install"
|
||||
fi
|
||||
INIT_TOR="pkill tor && tor"
|
||||
$green"\n\nDetected MacOS";$nocolor
|
||||
elif type -p apt > /dev/null; then
|
||||
check_tails
|
||||
if type -P apt > /dev/null; then
|
||||
# Debian / Ubuntu / Mint
|
||||
INSTALL="sudo apt install"
|
||||
INSTALL="sudo apt install -y"
|
||||
UPDATE="sudo apt update"
|
||||
INIT_TOR=$SYSTEMD_TOR
|
||||
elif type -p dnf > /dev/null; then
|
||||
$green"\nDetected Debian\n";$nocolor
|
||||
elif type -P dnf > /dev/null; then
|
||||
# Fedora
|
||||
INSTALL="sudo dnf install"
|
||||
INSTALL="sudo dnf install -y"
|
||||
UPDATE="sudo dnf check-update"
|
||||
INIT_TOR=$SYSTEMD_TOR
|
||||
$green"\n\nDetected Fedora";$nocolor
|
||||
elif type -p pacman > /dev/null; then
|
||||
$green"\nDetected Fedora\n";$nocolor
|
||||
elif type -P pacman > /dev/null; then
|
||||
# Arch Linux
|
||||
INSTALL="sudo pacman -S"
|
||||
UPDATE="sudo pacman -Syu"
|
||||
INIT_TOR=$SYSTEMD_TOR
|
||||
$green"\n\nDetected Arch Linux";$nocolor
|
||||
$green"\nDetected Arch Linux\n";$nocolor
|
||||
elif type -P brew > /dev/null; then
|
||||
# MacOS
|
||||
INSTALL="brew install"
|
||||
$green"\nDetected MacOS\n";$nocolor
|
||||
else
|
||||
$red"\nFailed to detect OS. Unsupported or unknown distribution.\nInstall Failed.\n";$nocolor
|
||||
$red"Failed to detect OS. Unsupported or unknown distribution.\nInstall Failed.";$nocolor
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
@ -60,8 +38,8 @@ detect_os_arch() {
|
|||
detect_os_arch
|
||||
|
||||
# Check for Tor installation
|
||||
if type -p tor > /dev/null; then
|
||||
printf "\nTor is already installed :)\n"
|
||||
if type -P tor > /dev/null; then
|
||||
echo -e "\nTor is already installed :)"
|
||||
else
|
||||
# Install and configure tor
|
||||
echo "Installing Tor..."
|
||||
|
@ -70,7 +48,7 @@ else
|
|||
fi
|
||||
|
||||
# Create HashedControlPassword
|
||||
printf "In the next step you'll choose a password. NOTE: It will be saved in PLAIN TEXT.\n"
|
||||
echo -e "In the next step you'll choose a password. NOTE: It will be saved in PLAIN TEXT."
|
||||
read -p "Enter a (new) tor control password [example: 123123] " torcontrolpass
|
||||
# Edit /etc/tor/torrc
|
||||
torhashedpass=$(tor --hash-password $torcontrolpass)
|
||||
|
@ -79,9 +57,9 @@ skipcontrol=$(sudo grep -x "$enabledcontrol" /etc/tor/torrc)
|
|||
echo "Check torrc for enabled ControlPort"
|
||||
if [[ $skipcontrol ]]; then
|
||||
# Use Existing enabled ControlPort and append HashedControlPassword
|
||||
printf "# Added by basicswap-bash\nHashedControlPassword $torhashedpass\n" | sudo tee -a /etc/tor/torrc
|
||||
echo -e "# Added by basicswap-bash\nHashedControlPassword $torhashedpass" | sudo tee -a /etc/tor/torrc
|
||||
else
|
||||
printf "# Added by basicswap-bash\n$enabledcontrol\nHashedControlPassword $torhashedpass\n" | sudo tee -a /etc/tor/torrc
|
||||
echo -e "# Added by basicswap-bash\n$enabledcontrol\nHashedControlPassword $torhashedpass" | sudo tee -a /etc/tor/torrc
|
||||
fi
|
||||
|
||||
# Restart tor to apply
|
||||
|
|
|
@ -26,13 +26,13 @@ MIN_TAKER=""
|
|||
############################
|
||||
|
||||
# Colors
|
||||
cy="printf \e[36;1m"
|
||||
cy="echo -e -n \e[36;1m"
|
||||
cy2="\e[36;1m"
|
||||
red="printf \e[31;1m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
red2="\e[31;1m"
|
||||
grn="printf \e[32;1m"
|
||||
grn="echo -e -n \e[32;1m"
|
||||
grn2="\e[32;1m"
|
||||
nc="printf \e[0m"
|
||||
nc="echo -e -n \e[0m"
|
||||
nc2="\e[0m"
|
||||
|
||||
# Choose Coins
|
||||
|
@ -48,7 +48,7 @@ coin_prompt_sell() {
|
|||
}
|
||||
coin() {
|
||||
coin=""
|
||||
printf "\n[1] Bitcoin\n[2] Monero\n[3] Litecoin\n[4] Firo\n[5] Dash\n[6] Decred\n[7] PIVX\n[8] Particl\n[9] Wownero\n\n"
|
||||
echo -e "\n[1] Bitcoin\n[2] Monero\n[3] Litecoin\n[4] Firo\n[5] Dash\n[6] Decred\n[7] PIVX\n[8] Particl\n[9] Wownero\n"
|
||||
until [[ $coin =~ ^[1-9]$ ]]; do
|
||||
read -p 'Select an option: ' coin
|
||||
case $coin in
|
||||
|
@ -88,7 +88,7 @@ coin() {
|
|||
coinname="Wownero"
|
||||
coinsymbol="WOW"
|
||||
;;
|
||||
*) $red"\nYou must answer 1-9\n"; $nc
|
||||
*) $red "\nYou must answer 1-9\n"; $nc
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
@ -126,56 +126,48 @@ book_min() {
|
|||
}
|
||||
|
||||
set_fiat() {
|
||||
printf "[1] USD [default]\n[2] EUR\n[3] CAD\n[4] AUD\n[5] CUSTOM\n\n"
|
||||
echo -e "[1] USD [default]\n[2] EUR\n[3] CAD\n[4] AUD\n[5] CUSTOM"
|
||||
read -p 'Select an option: ' fiat_select
|
||||
case $fiat_select in
|
||||
1) FIAT=USD
|
||||
fiat=usd
|
||||
echo "USD"
|
||||
;;
|
||||
2) FIAT=EUR
|
||||
fiat=eur
|
||||
echo "EUR"
|
||||
;;
|
||||
3) FIAT=CAD
|
||||
fiat=cad
|
||||
echo "CAD"
|
||||
;;
|
||||
4) FIAT=AUD
|
||||
fiat=aud
|
||||
echo "AUD"
|
||||
;;
|
||||
5) read -p 'Please enter the lowecase 3 character currency code [example: jpy] ' FIAT
|
||||
fiat=$FIAT
|
||||
;;
|
||||
*) FIAT=USD
|
||||
fiat=usd
|
||||
echo "USD"
|
||||
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
coin_price() {
|
||||
printf "\n\nCurrent Market Rates are..\n"
|
||||
curl -s "https://api.coingecko.com/api/v3/simple/price?ids=$THEIR_COIN,$YOUR_COIN&vs_currencies=$fiat" > rates.txt
|
||||
YOUR_FIAT=$(cat rates.txt | jq -r ".$YOUR_COIN.$fiat")
|
||||
THEIR_FIAT=$(cat rates.txt | jq -r ".$THEIR_COIN.$fiat")
|
||||
echo -e "\nCurrent Market Rates are.."
|
||||
YOUR_FIAT=$(curl -s "https://api.coingecko.com/api/v3/simple/price?ids=$THEIR_COIN,$YOUR_COIN&vs_currencies=$fiat" | jq -r ".$YOUR_COIN.$fiat")
|
||||
THEIR_FIAT=$(curl -s "https://api.coingecko.com/api/v3/simple/price?ids=$THEIR_COIN,$YOUR_COIN&vs_currencies=$fiat" | jq -r ".$THEIR_COIN.$fiat")
|
||||
TAKER_RATE=$(echo $THEIR_FIAT $YOUR_FIAT | awk '{ printf "%.8f\n", $1 / $2 }' )
|
||||
MAKER_RATE=$(echo $TAKER_RATE | awk '{ printf "%.8f\n", 1 / $1 }')
|
||||
$cy"$THEIR_FIAT $FIAT$nc2/$grn2$theircoin$nc2 which is $red2$TAKER_RATE $yourcoin$nc2/$grn2$theircoin$nc2\n"
|
||||
$cy"$YOUR_FIAT $FIAT$nc2/$red2$yourcoin$nc2 which is $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin$nc2\n"
|
||||
rm rates.txt
|
||||
}
|
||||
|
||||
buy_sell() {
|
||||
printf "\n\n[1] BUY a specific amount of $grn2$theircapital$nc2\n[2] SELL a specific amount of your $red2$yourcapital$nc2\n\n"
|
||||
echo -e "\n[1] BUY a specific amount of $grn2$theircapital$nc2\n[2] SELL a specific amount of your $red2$yourcapital$nc2\n"
|
||||
until [[ $BUYORSELL =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option: ' BUYORSELL
|
||||
case $BUYORSELL in
|
||||
1) read -p $'\nHow much '"$theircapital"' do you want to BUY? [example: 1] ' AMOUNT
|
||||
$cy"\nRate you will pay:\n";$nc
|
||||
printf "\n[1] CUSTOM: Specific Crypto Rate $red2$yourcoin$nc2/$grn2$theircoin$nc2\n[2] CUSTOM: $red2$TAKER_RATE $yourcoin$nc2/$grn2$theircoin $cy2+/- CUSTOM Percent$nc2\n[3] PRESET: $red2$TAKER_RATE $yourcoin$nc2/$grn2$theircoin$nc2\n[4] PRESET: $red2$TAKER_RATE $yourcoin$nc2/$grn2$theircoin $cy2+ $PERCENT%%$nc2\n[ENTER] FIAT: Enter a $cy2$FIAT$nc2 rate to pay\n\n"
|
||||
1) read -p "How much $theircapital do you want to BUY? [example: 1] " AMOUNT
|
||||
$cy "\nRate you will pay:\n";$nc
|
||||
echo -e "[1] CUSTOM: Specific Crypto Rate $red2$yourcoin$nc2/$grn2$theircoin$nc2\n[2] CUSTOM: $red2$TAKER_RATE $yourcoin$nc2/$grn2$theircoin $cy2+/- CUSTOM Percent$nc2\n[3] PRESET: $red2$TAKER_RATE $yourcoin$nc2/$grn2$theircoin$nc2\n[4] PRESET: $red2$TAKER_RATE $yourcoin$nc2/$grn2$theircoin $cy2+ $PERCENT%$nc2\n[ENTER] FIAT: Enter a $cy2$FIAT$nc2 rate to pay"
|
||||
read -p 'Select an option: ' RATESEL
|
||||
case $RATESEL in
|
||||
1) read -p $"At what rate would you like to Pay? [example: $TAKER_RATE] " RATE
|
||||
|
@ -199,12 +191,12 @@ buy_sell() {
|
|||
;;
|
||||
esac
|
||||
MAKER_RATE=$(echo $RATE | awk '{ printf "%.8f\n", 1 / $1 }')
|
||||
printf "\nPaying: $red2 $PRICE$FIAT$nc2 which is $red2($RATE $yourcoin$nc2/$grn2$theircoin$nc2)\n"
|
||||
printf "Rate to be paid: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin$nc2\n\n"
|
||||
echo -e "\nPaying: $red2 $PRICE$FIAT$nc2 which is $red2($RATE $yourcoin$nc2/$grn2$theircoin$nc2)"
|
||||
echo -e "Rate to be paid: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin$nc2\n"
|
||||
;;
|
||||
2) read -p $'\nHow much YOUR '"$yourcapital"' do you want to SELL [example: 1] ' AMOUNT
|
||||
$cy"\nRate to charge:\n";$nc
|
||||
printf "\n[1] CUSTOM: Specific Crypto Rate $grn2$theircoin$nc2/$red2$yourcoin$nc2\n[2] CUSTOM: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin $cy2+/- CUSTOM Percent$nc2\n[3] PRESET: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin$nc2\n[4] PRESET: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin $cy2+ $PERCENT%%$nc2\n[ENTER] FIAT: Enter a $cy2$FIAT$nc2 rate to charge\n\n"
|
||||
2) read -p "How much YOUR $yourcapital do you want to SELL [example: 1] " AMOUNT
|
||||
$cy "\nRate to charge:\n";$nc
|
||||
echo -e "[1] CUSTOM: Specific Crypto Rate $grn2$theircoin$nc2/$red2$yourcoin$nc2\n[2] CUSTOM: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin $cy2+/- CUSTOM Percent$nc2\n[3] PRESET: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin$nc2\n[4] PRESET: $grn2$MAKER_RATE $theircoin$nc2/$red2$yourcoin $cy2+ $PERCENT%$nc2\n[ENTER] FIAT: Enter a $cy2$FIAT$nc2 rate to charge"
|
||||
read -p 'Select an option: ' RATESEL
|
||||
case $RATESEL in
|
||||
1) read -p $"Enter specific rate to Charge? [example: $MAKER_RATE] " RATE
|
||||
|
@ -228,9 +220,9 @@ buy_sell() {
|
|||
;;
|
||||
esac
|
||||
TAKER_RATE=$(echo $RATE | awk '{ printf "%.8f\n", 1 / $1 }')
|
||||
printf "Selling at $PRICE$FIAT which is a rate of $grn2$RATE $theircoin$nc2/$red2$yourcoin$nc2\n"
|
||||
echo -e "Selling at $PRICE$FIAT which is a rate of $grn2$RATE $theircoin$nc2/$red2$yourcoin$nc2"
|
||||
;;
|
||||
*) $red"\nYou must answer 1 or 2\n"; $nc
|
||||
*) $red "\nYou must answer 1 or 2\n"; $nc
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
@ -240,7 +232,7 @@ buy_sell() {
|
|||
split_orders() {
|
||||
if [ $ALLOW_SPLIT_ORDERS = true ]; then
|
||||
MIN_SWAP=$(echo $AMOUNT $MAXBIDS | awk '{ printf "%.0f\n", $1 / $2 }')
|
||||
printf "$cy2#TODO$nc2 Splitting into multiple bids if necessary. $red2$MAXBIDS$nc2 tx at most\n"
|
||||
echo -e "$cy2#TODO$nc2 Splitting into multiple bids if necessary. $red2$MAXBIDS$nc2 tx at most"
|
||||
else
|
||||
MIN_SWAP=$AMOUNT
|
||||
$red"One order only. Not Recommended";$nc
|
||||
|
@ -257,14 +249,14 @@ apply_config() {
|
|||
sed -i -z "s/COIN_TO_BUY/$theircapital/" $taker $maker
|
||||
sed -i -z "s/PERCENT/$PERCENT/" $maker
|
||||
sed -i -z "s/MAXBIDS/$MAXBIDS/" $taker
|
||||
printf "\nMinumum amt per swap = $grn2$MIN_TAKER $theircoin$nc2\n"
|
||||
printf " = $red2$MIN_SWAP $yourcoin$nc2\n\n"
|
||||
echo -e "\nMinumum amt per swap = $grn2$MIN_TAKER $theircoin$nc2"
|
||||
echo -e " = $red2$MIN_SWAP $yourcoin$nc2\n"
|
||||
if [[ $BUYORSELL = 1 ]]; then
|
||||
MAKERAMOUNT=$(echo $AMOUNT $MAKER_RATE | awk '{ printf "%.8f\n", $1 / $2 }')
|
||||
OB_AMOUNT=$MAKERAMOUNT
|
||||
INCREMENT=$(echo $OB_AMOUNT | awk '{ printf "%.4f", $1 / 10 }')
|
||||
printf "Outgoing: $red2$MAKERAMOUNT $yourcoin$nc2\n"
|
||||
printf "Incoming: $grn2~$AMOUNT $theircoin$nc2\n"
|
||||
echo -e "Outgoing: $red2$MAKERAMOUNT $yourcoin$nc2"
|
||||
echo -e "Incoming: $grn2~$AMOUNT $theircoin$nc2"
|
||||
sed -i -z "s/AMOUNT/$MAKERAMOUNT/g" $maker
|
||||
sed -i -z "s/RATE/$MAKER_RATE/" $maker
|
||||
sed -i -z "s/RATE/$RATE/" $taker
|
||||
|
@ -274,8 +266,8 @@ apply_config() {
|
|||
TAKERAMOUNT=$(echo $AMOUNT $MAKER_RATE | awk '{ printf "%.8f\n", $1 * $2 }')
|
||||
OB_AMOUNT=$AMOUNT
|
||||
INCREMENT=$(echo $OB_AMOUNT | awk '{ printf "%.4f", $1 / 10 }')
|
||||
printf "Outgoing: $red2$AMOUNT $yourcoin$nc2\n"
|
||||
printf "Incoming: $grn2~$TAKERAMOUNT $theircoin$nc2\n"
|
||||
echo -e "Outgoing: $red2$AMOUNT $yourcoin$nc2"
|
||||
echo -e "Incoming: $grn2~$TAKERAMOUNT $theircoin$nc2"
|
||||
sed -i -z "s/AMOUNT/$TAKERAMOUNT/g" $taker
|
||||
sed -i -z "s/RATE/$TAKER_RATE/" $taker
|
||||
sed -i -z "s/RATE/$RATE/" $maker
|
||||
|
@ -292,24 +284,28 @@ revert_config() {
|
|||
|
||||
check_bids() {
|
||||
# oneshot. Check for matching offers before posting one
|
||||
revert_config
|
||||
apply_config
|
||||
FOUNDBID=$(python3 createoffers.py --configfile $taker --statefile $state --port=$PORT --oneshot --debug | grep "New bid")
|
||||
FOUNDBID=$(python createoffers.py --configfile $taker --statefile $state --port=$PORT --oneshot --debug | grep "New bid")
|
||||
if [[ $FOUNDBID ]]; then
|
||||
$grn"Placed bid successfully! Check BasicSwapDEX to confirm\n";$nc
|
||||
elif [[ $OB_AMOUNT < $OB_MIN && -z $FOUNDBID ]]; then
|
||||
printf "Checking for a matching offer\n"
|
||||
printf "No matching offers found $red2:@ !!!$nc2\nBid quantity too$red2 low$nc2 to post to order book.\nTrying again in 30 seconds\n"
|
||||
sleep 30
|
||||
echo -e "Checking for a matching offer"
|
||||
echo -e "No matching offers found $red2:@ !!!$nc2\nBid quantity too$red2 low$nc2 to post to order book.\nTrying again in 30 seconds"
|
||||
sleep 2
|
||||
revert_config
|
||||
sleep 28
|
||||
apply_config
|
||||
$cy"Rechecking bids\n";$nc
|
||||
recheck_bids
|
||||
else
|
||||
# Post as limit order on the book
|
||||
$cy"No matching offers found. Posting to the orderbook\n";$nc
|
||||
ORDERPLACED=$(python3 createoffers.py --configfile $maker --statefile $state --port=$PORT --oneshot | grep "New offer")
|
||||
ORDERPLACED=$(python createoffers.py --configfile $maker --statefile $state --port=$PORT --oneshot | grep "New offer")
|
||||
if [[ $ORDERPLACED ]]; then
|
||||
revert_config
|
||||
$grn"OFFER POSTED! Please check BasicSwapDEX to confirm\nOffer expires in 4hrs\n";$nc
|
||||
else
|
||||
revert_config
|
||||
$red"Placing Order failed. Try again$nc2\n"
|
||||
fi
|
||||
fi
|
||||
|
@ -332,8 +328,8 @@ recheck_bids() {
|
|||
coin
|
||||
coin_prompt_sell
|
||||
|
||||
printf "\nBuying: $grn2$theircapital$nc2"
|
||||
printf "\nSelling: $red2$yourcapital$nc2\n"
|
||||
echo -e "Buying: $grn2$theircapital$nc2"
|
||||
echo -e "Selling: $red2$yourcapital$nc2"
|
||||
|
||||
#2. Set rates
|
||||
# Pull Market rate
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
## Prompt for user input
|
||||
printf "\n\nThe following coins can be disabled (case sensitive)\nbitcoin\ndash\ndecred\nfiro\nlitecoin\nmonero\npivx\nwownero\n\n"
|
||||
echo -e "\n\nThe following coins can be disabled (case sensitive)\nbitcoin\ndash\ndecred\nfiro\nlitecoin\nmonero\npivx\nwownero\n"
|
||||
read -p 'Full name of coin to disable [example: wownero] ' disablecoin
|
||||
## Confirm
|
||||
printf "\nDisable $disablecoin on your BasicSwap install, correct? Press any key to continue. CTRL-C to exit\n"
|
||||
echo -e "\nDisable $disablecoin on your BasicSwap install, correct? Press any key to continue. CTRL-C to exit"
|
||||
read
|
||||
## Disable the coin
|
||||
basicswap-prepare --datadir=$SWAP_DATADIR --disablecoin=$disablecoin
|
||||
|
|
16
bsx/setup.sh
16
bsx/setup.sh
|
@ -1,9 +1,9 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
## Clone basicswap git
|
||||
cd $SWAP_DATADIR
|
||||
|
@ -12,12 +12,12 @@ cd $SWAP_DATADIR/basicswap
|
|||
|
||||
## Macos
|
||||
if [[ $MACOS ]]; then
|
||||
$SWAP_DATADIR/venv/bin/pip3 install certifi
|
||||
$SWAP_DATADIR/venv/bin/pip install certifi
|
||||
fi
|
||||
|
||||
## Install basicswap, coincurve, and pip dependencies
|
||||
$SWAP_DATADIR/venv/bin/pip3 install -r requirements.txt --require-hashes
|
||||
$SWAP_DATADIR/venv/bin/pip3 install .
|
||||
$SWAP_DATADIR/venv/bin/pip install -r requirements.txt --require-hashes
|
||||
$SWAP_DATADIR/venv/bin/pip install .
|
||||
|
||||
## Decide a source for Monero's restore height
|
||||
if [[ "$xmrrestoreheight" ]]; then
|
||||
|
@ -53,12 +53,12 @@ elif [[ "$monerod_addr" ]]; then
|
|||
# Setup new install and use a remote monero node
|
||||
XMR_RPC_HOST=$monerod_addr XMR_RPC_PORT=$monerod_port \
|
||||
basicswap-prepare --datadir=$SWAP_DATADIR --withcoins=monero,wownero --xmrrestoreheight=$CURRENT_XMR_HEIGHT --wowrestoreheight=600000
|
||||
$red"\n\nMake note of your seed above\n\n"; $nocolor
|
||||
$red"\n\nMake note of your seed above\n"; $nocolor
|
||||
enable_tor
|
||||
else
|
||||
# Setup new install using local nodes
|
||||
basicswap-prepare --datadir=$SWAP_DATADIR --withcoins=monero,wownero --xmrrestoreheight=$CURRENT_XMR_HEIGHT --wowrestoreheight=600000
|
||||
$red"\n\nMake note of your seed above\n\n"; $nocolor
|
||||
$red"\n\nMake note of your seed above\n"; $nocolor
|
||||
enable_tor
|
||||
fi
|
||||
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
## Clone basicswap git
|
||||
cd $SWAP_DATADIR
|
||||
|
@ -12,12 +12,12 @@ cd $SWAP_DATADIR/basicswap
|
|||
|
||||
## Macos
|
||||
if [[ $MACOS ]]; then
|
||||
$SWAP_DATADIR/venv/bin/pip3 install certifi
|
||||
$SWAP_DATADIR/venv/bin/pip install certifi
|
||||
fi
|
||||
|
||||
## Install basicswap, coincurve, and pip dependencies
|
||||
torsocks $SWAP_DATADIR/venv/bin/pip3 install -r requirements.txt --require-hashes
|
||||
torsocks $SWAP_DATADIR/venv/bin/pip3 install .
|
||||
torsocks $SWAP_DATADIR/venv/bin/pip install -r requirements.txt --require-hashes
|
||||
torsocks $SWAP_DATADIR/venv/bin/pip install .
|
||||
|
||||
## Decide a source for Monero's restore height
|
||||
if [[ "$xmrrestoreheight" ]]; then
|
||||
|
@ -53,12 +53,12 @@ elif [[ "$monerod_addr" ]]; then
|
|||
# Setup new install and use a remote monero node
|
||||
XMR_RPC_HOST=$monerod_addr XMR_RPC_PORT=$monerod_port \
|
||||
basicswap-prepare --datadir=$SWAP_DATADIR --withcoins=monero,wownero --xmrrestoreheight=$CURRENT_XMR_HEIGHT --wowrestoreheight=600000
|
||||
$red"\n\nMake note of your seed above\n\n"; $nocolor
|
||||
$red"\n\nMake note of your seed above\n"; $nocolor
|
||||
enable_tor
|
||||
else
|
||||
# Setup new install using local nodes
|
||||
basicswap-prepare --datadir=$SWAP_DATADIR --withcoins=monero,wownero --xmrrestoreheight=$CURRENT_XMR_HEIGHT --wowrestoreheight=600000
|
||||
$red"\n\nMake note of your seed above\n\n"; $nocolor
|
||||
$red"\n\nMake note of your seed above\n"; $nocolor
|
||||
enable_tor
|
||||
fi
|
||||
|
||||
|
|
|
@ -16,8 +16,8 @@ fi
|
|||
|
||||
#git checkout master
|
||||
git pull
|
||||
$SWAP_DATADIR/venv/bin/pip3 install -r requirements.txt --require-hashes
|
||||
$SWAP_DATADIR/venv/bin/pip3 install .
|
||||
$SWAP_DATADIR/venv/bin/pip install -r requirements.txt --require-hashes
|
||||
$SWAP_DATADIR/venv/bin/pip install .
|
||||
|
||||
# Update Coin Cores
|
||||
$HOME/.local/bin/bsx/auto_coinupd8.sh
|
||||
|
|
68
install.sh
68
install.sh
|
@ -2,9 +2,9 @@
|
|||
export SWAP_DATADIR=$HOME/coinswaps
|
||||
|
||||
# Colors
|
||||
red="printf \e[31;1m"
|
||||
green="printf \e[32;1m"
|
||||
nocolor="printf \e[0m"
|
||||
red="echo -e -n \e[31;1m"
|
||||
green="echo -e -n \e[32;1m"
|
||||
nocolor="echo -e -n \e[0m"
|
||||
|
||||
# Check if basicswap is running
|
||||
if [[ -f $SWAP_DATADIR/particl/particl.pid ]]; then
|
||||
|
@ -24,9 +24,9 @@ title="BasicSwapDEX Installer"
|
|||
COLUMNS=$(tput cols)
|
||||
title_size=${#title}
|
||||
span=$(((COLUMNS + title_size) / 2))
|
||||
printf "%${COLUMNS}s" " " | tr " " "#"
|
||||
printf "%${COLUMNS}s" " " | tr " " "*"
|
||||
printf "%${span}s\n" "$title"
|
||||
printf "%${COLUMNS}s" " " | tr " " "#"
|
||||
printf "%${COLUMNS}s" " " | tr " " "*"
|
||||
$nocolor
|
||||
|
||||
# Detect Operating system
|
||||
|
@ -36,11 +36,11 @@ DEPENDENCY=""
|
|||
TAILS=""
|
||||
|
||||
check_tails() {
|
||||
if [[ $USER == amnesia ]]; then
|
||||
$green"\n\nDetected Tails";$nocolor
|
||||
if [ $USER == amnesia ]; then
|
||||
$green"\nDetected Tails\n";$nocolor
|
||||
TAILS=1
|
||||
else
|
||||
$green"\n\nDetected Debian";$nocolor
|
||||
$green"\nDetected Debian\n";$nocolor
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -48,7 +48,7 @@ detect_os_arch() {
|
|||
if [[ $(uname -s) = "Darwin" ]]; then
|
||||
# MacOS
|
||||
export MACOS=1
|
||||
if type -p brew > /dev/null; then
|
||||
if type -P brew > /dev/null; then
|
||||
$green"Homebrew is installed\n";$nc
|
||||
INSTALL="brew install"
|
||||
else
|
||||
|
@ -56,27 +56,27 @@ detect_os_arch() {
|
|||
INSTALL="curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh | /bin/bash && brew install"
|
||||
fi
|
||||
DEPENDENCY="python gnupg pkg-config"
|
||||
$green"\n\nDetected MacOS";$nocolor
|
||||
elif type -p apt > /dev/null; then
|
||||
$green"\nDetected MacOS\n";$nocolor
|
||||
elif type -P apt > /dev/null; then
|
||||
check_tails
|
||||
# Debian / Ubuntu / Mint
|
||||
INSTALL="sudo apt install"
|
||||
UPDATE="sudo apt update"
|
||||
DEPENDENCY="python3-pip python3-venv gnupg pkg-config"
|
||||
elif type -p dnf > /dev/null; then
|
||||
elif type -P dnf > /dev/null; then
|
||||
# Fedora
|
||||
INSTALL="sudo dnf install"
|
||||
UPDATE="sudo dnf check-update"
|
||||
DEPENDENCY="python3-virtualenv python3-pip python3-devel gnupg2 pkgconf"
|
||||
$green"\n\nDetected Fedora";$nocolor
|
||||
elif type -p pacman > /dev/null; then
|
||||
$green"\nDetected Fedora\n";$nocolor
|
||||
elif type -P pacman > /dev/null; then
|
||||
# Arch Linux
|
||||
INSTALL="sudo pacman -S"
|
||||
UPDATE="sudo pacman -Syu"
|
||||
DEPENDENCY="curl python-pipenv gnupg pkgconf base-devel"
|
||||
$green"\n\nDetected Arch Linux";$nocolor
|
||||
DEPENDENCY="python-pipenv gnupg pkgconf base-devel"
|
||||
$green"\nDetected Arch Linux\n";$nocolor
|
||||
else
|
||||
$red"\nFailed to detect OS. Unsupported or unknown distribution.\nInstall Failed.\n";$nocolor
|
||||
$red"Failed to detect OS. Unsupported or unknown distribution.\nInstall Failed.";$nocolor
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
@ -84,21 +84,21 @@ detect_os_arch() {
|
|||
detect_os_arch
|
||||
|
||||
## Update & Install dependencies
|
||||
printf "\n\nInstalling dependencies\nPress CTRL-C at password prompt(s) to skip. If skipped, you must install the dependencies manually before proceeding\n\n"
|
||||
echo -e "\n\nInstalling dependencies\nPress CTRL-C at password prompt(s) to skip. If skipped, you must install the dependencies manually before proceeding"
|
||||
$green"$UPDATE\n$INSTALL $DEPENDENCY curl automake libtool jq\n"; $nocolor
|
||||
$UPDATE
|
||||
$INSTALL $DEPENDENCY automake libtool jq
|
||||
$INSTALL $DEPENDENCY curl automake libtool jq
|
||||
|
||||
# Enable tor
|
||||
printf "\n[1] Tor ON (requires sudo)\n[2] Tor OFF\n"
|
||||
echo -e "\n\n[1] Tor ON (requires sudo)\n[2] Tor OFF\n"
|
||||
until [[ "$tor_on" =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option: [1|2] ' tor_on
|
||||
case $tor_on in
|
||||
1)
|
||||
$green"BasicSwapDEX will use Tor\n";$nocolor
|
||||
$green"\nBasicSwapDEX will use Tor";$nocolor
|
||||
;;
|
||||
2)
|
||||
$red"BasicSwapDEX will NOT use Tor\n";$nocolor
|
||||
$red"\nBasicSwapDEX will NOT use Tor";$nocolor
|
||||
;;
|
||||
*)
|
||||
$red"You must answer 1 or 2\n";$nocolor
|
||||
|
@ -107,22 +107,22 @@ read -p 'Select an option: [1|2] ' tor_on
|
|||
done
|
||||
|
||||
## Particl restore Seed
|
||||
printf "\n[1] New Install (default)\n[2] Restore from Particl Seed\n"
|
||||
echo -e "\n\n[1] New Install (default)\n[2] Restore from Particl Seed\n"
|
||||
until [[ "$restore" =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option: [1|2] ' restore
|
||||
case $restore in
|
||||
1)
|
||||
$green"Installing BasicSwapDEX\n"; $nocolor
|
||||
$green"\nInstalling BasicSwapDEX\n"; $nocolor
|
||||
;;
|
||||
2)
|
||||
until [[ "$wordcount" = "24" ]]; do
|
||||
read -p $'\nEnter your Particl Seed\n[example: word word word word word...] ' particl_mnemonic
|
||||
wordcount=$(echo $particl_mnemonic | wc -w)
|
||||
if [[ $wordcount = 24 ]]; then
|
||||
printf "Restoring BasicSwapDEX\n"
|
||||
echo -e "Restoring BasicSwapDEX"
|
||||
$green"$particl_mnemonic\n";$nocolor
|
||||
else
|
||||
$red"Try again. Seed must be 24 words\n"; $nocolor
|
||||
$red"Try again. Seed must be 24 words"; $nocolor
|
||||
fi
|
||||
done
|
||||
;;
|
||||
|
@ -137,13 +137,13 @@ if [[ $particl_mnemonic ]]; then
|
|||
read -p $'\nEnter a restore height for your BasicSwap XMR wallet? [Y/n] ' height
|
||||
case $height in
|
||||
n|N)
|
||||
$red"Not using a custom XMR Restore height\n";$nocolor
|
||||
$red"\nNot using a custom XMR Restore height";$nocolor
|
||||
;;
|
||||
*)
|
||||
until [[ "$xmrrestoreheight" =~ ^[0-9]{1,7}$ ]]; do
|
||||
read -p $'Enter your Monero Restore Height [example: 2548568] ' xmrrestoreheight
|
||||
if [[ $xmrrestoreheight =~ ^[0-9]{7}$ ]]; then
|
||||
$green"Your XMR Restore height: $xmrrestoreheight\n"; $nocolor
|
||||
$green"\nYour XMR Restore height: $xmrrestoreheight"; $nocolor
|
||||
else
|
||||
$red"Try again. Must be 1-7 digits\n"; $nocolor
|
||||
fi
|
||||
|
@ -153,7 +153,7 @@ if [[ $particl_mnemonic ]]; then
|
|||
fi
|
||||
|
||||
## Configure Monero
|
||||
printf "\n[1] Connect to a Monero node\n[2] Allow BasicSwapDEX to run a Monero node (+70GB)\n"
|
||||
echo -e "\n[1] Connect to a Monero node\n[2] Allow BasicSwapDEX to run a Monero node (+70GB)\n"
|
||||
until [[ "$l" =~ ^[12]$ ]]; do
|
||||
read -p 'Select an option [1|2]: ' l
|
||||
case $l in
|
||||
|
@ -161,16 +161,16 @@ read -p 'Select an option [1|2]: ' l
|
|||
until [[ $checknode ]]; do
|
||||
read -p 'Enter Address of Monero node [example: 192.168.1.123] ' monerod_addr
|
||||
read -p 'Enter RPC Port for the Monero node [example: 18081] ' monerod_port
|
||||
checknode=$(curl -sk http://$monerod_addr:$monerod_port/get_info | jq .height)
|
||||
checknode=$(curl -sk http://$monerod_addr:$monerod_port/get_info)
|
||||
if [[ $checknode ]]; then
|
||||
$green"Successfully connected to the XMR node @ $monerod_addr:$monerod_port\n"; $nocolor
|
||||
$green"\nSuccessfully connected to the XMR node @ $monerod_addr:$monerod_port"; $nocolor
|
||||
else
|
||||
$red"The node at $monerod_addr:$monerod_port is not accessible. Try again\n"; $nocolor
|
||||
$red"\nThe node at $monerod_addr:$monerod_port is not accessible. Try again\n\n"; $nocolor
|
||||
fi
|
||||
done
|
||||
;;
|
||||
2)
|
||||
$green"BasicSwapDEX will run the Monero node for you.\n"; $nocolor
|
||||
$green"\nBasicSwapDEX will run the Monero node for you."; $nocolor
|
||||
;;
|
||||
*)
|
||||
$red"You must answer 1 or 2\n"; $nocolor
|
||||
|
@ -179,7 +179,7 @@ read -p 'Select an option [1|2]: ' l
|
|||
done
|
||||
|
||||
## Begin Install
|
||||
printf "\nInstalling BasicSwapDEX\n"
|
||||
echo -e "\n\nInstalling BasicSwapDEX"
|
||||
read -p 'Press Enter to continue, or CTRL-C to exit.'
|
||||
|
||||
# Quest to make trasher happy
|
||||
|
|
Loading…
Reference in a new issue