2020-01-22 22:24:21 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
2020-09-21 12:00:07 +01:00
|
|
|
/home/joinmarket/start.joininbox.sh
|
2020-06-13 16:48:31 +01:00
|
|
|
source /home/joinmarket/joinin.conf
|
2020-09-30 13:58:32 +01:00
|
|
|
source /home/joinmarket/_functions.sh
|
2020-01-22 22:24:21 +00:00
|
|
|
|
|
|
|
|
# BASIC MENU INFO
|
2020-12-14 20:04:37 +00:00
|
|
|
HEIGHT=25
|
2020-06-20 13:09:22 +01:00
|
|
|
WIDTH=57
|
2020-12-14 20:04:37 +00:00
|
|
|
CHOICE_HEIGHT=21
|
2021-02-10 12:37:01 +00:00
|
|
|
BACKTITLE="JoininBox GUI $currentJBtag network:$network IP:$localip"
|
|
|
|
|
TITLE="JoininBox $currentJBtag $network"
|
2020-06-20 13:09:22 +01:00
|
|
|
MENU="
|
|
|
|
|
Choose from the options:"
|
2020-01-22 22:24:21 +00:00
|
|
|
OPTIONS=()
|
|
|
|
|
|
|
|
|
|
# Basic Options
|
|
|
|
|
OPTIONS+=(\
|
2020-06-14 09:34:45 +01:00
|
|
|
INFO "Show the address list and balances" \
|
|
|
|
|
QTGUI "Show how to open the JoinMarketQT GUI" \
|
2020-06-13 20:01:18 +01:00
|
|
|
"" ""
|
2020-06-15 15:37:19 +01:00
|
|
|
WALLET "Wallet management options" \
|
|
|
|
|
MAKER "Yield Generator options" \
|
2020-01-22 22:24:21 +00:00
|
|
|
"" ""
|
2020-06-20 13:09:22 +01:00
|
|
|
SEND "Pay to an address with/without a coinjoin" \
|
|
|
|
|
FREEZE "Exercise coin control within a mixdepth" \
|
|
|
|
|
PAYJOIN "Send/Receive between JoinMarket wallets"
|
2020-01-22 22:24:21 +00:00
|
|
|
"" ""
|
2020-10-27 15:07:16 +00:00
|
|
|
OFFERS "Watch the Order Book locally" \
|
2020-06-15 15:37:19 +01:00
|
|
|
"" ""
|
2021-02-09 17:05:39 +00:00
|
|
|
CONFIG "Connection and joinmarket.cfg settings" \
|
2020-12-15 00:44:48 +00:00
|
|
|
TOOLS "Extra helper functions and Boltzmann"
|
2020-09-09 11:20:41 +01:00
|
|
|
UPDATE "Update JoininBox or JoinMarket" \
|
2020-06-15 15:37:19 +01:00
|
|
|
"" ""
|
2020-01-22 22:24:21 +00:00
|
|
|
X "Exit to the Command Line" \
|
2020-12-14 20:04:37 +00:00
|
|
|
#CONNECT "Connect to a remote bitcoind" \
|
2020-06-13 20:01:18 +01:00
|
|
|
#TUMBLER "Run the Tumbler to mix quickly" \
|
2020-01-22 22:24:21 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
|
|
CHOICE=$(dialog --clear \
|
|
|
|
|
--backtitle "$BACKTITLE" \
|
|
|
|
|
--title "$TITLE" \
|
|
|
|
|
--menu "$MENU" \
|
|
|
|
|
$HEIGHT $WIDTH $CHOICE_HEIGHT \
|
|
|
|
|
"${OPTIONS[@]}" \
|
|
|
|
|
2>&1 >/dev/tty)
|
|
|
|
|
|
|
|
|
|
case $CHOICE in
|
2020-06-21 01:03:29 +01:00
|
|
|
INFO)
|
2020-06-22 15:15:28 +01:00
|
|
|
# wallet
|
|
|
|
|
chooseWallet
|
2020-06-22 20:53:27 +01:00
|
|
|
# mixdepth
|
2020-09-09 09:50:47 +01:00
|
|
|
mixdepth=$(mktemp 2>/dev/null)
|
2020-06-22 20:53:27 +01:00
|
|
|
dialog --backtitle "Choose a mixdepth" \
|
|
|
|
|
--title "Choose a mixdepth" \
|
|
|
|
|
--inputbox "
|
|
|
|
|
Enter a number between 0 to 4 to limit the visible mixdepths
|
2020-07-05 09:03:10 +01:00
|
|
|
Leave the box empty to show the addresses in all five" 10 64 2> $mixdepth
|
2020-06-22 20:53:27 +01:00
|
|
|
openMenuIfCancelled $?
|
2020-09-09 09:50:47 +01:00
|
|
|
/home/joinmarket/start.script.sh wallet-tool "$(cat $wallet)" nooption "$(cat $mixdepth)"
|
2020-06-21 01:03:29 +01:00
|
|
|
echo ""
|
|
|
|
|
echo "Fund the wallet on addresses labeled 'new' to avoid address reuse."
|
2020-06-21 11:33:57 +01:00
|
|
|
echo ""
|
2020-10-14 01:18:11 +01:00
|
|
|
echo "Press ENTER to return to the menu..."
|
|
|
|
|
read key
|
|
|
|
|
/home/joinmarket/menu.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
;;
|
|
|
|
|
WALLET)
|
|
|
|
|
/home/joinmarket/menu.wallet.sh
|
|
|
|
|
/home/joinmarket/menu.sh
|
|
|
|
|
;;
|
|
|
|
|
QTGUI)
|
|
|
|
|
/home/joinmarket/info.qtgui.sh
|
|
|
|
|
/home/joinmarket/menu.sh
|
|
|
|
|
;;
|
|
|
|
|
MAKER)
|
|
|
|
|
/home/joinmarket/menu.yg.sh
|
|
|
|
|
/home/joinmarket/menu.sh
|
|
|
|
|
;;
|
|
|
|
|
SEND)
|
|
|
|
|
/home/joinmarket/menu.send.sh
|
2020-10-14 01:18:11 +01:00
|
|
|
echo ""
|
|
|
|
|
echo "Press ENTER to return to the menu..."
|
|
|
|
|
read key
|
2020-08-15 15:15:40 +01:00
|
|
|
/home/joinmarket/menu.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
;;
|
|
|
|
|
FREEZE)
|
|
|
|
|
/home/joinmarket/menu.freeze.sh
|
2020-11-09 23:39:59 +00:00
|
|
|
echo ""
|
|
|
|
|
echo "Press ENTER to return to the menu..."
|
|
|
|
|
read key
|
2020-08-15 15:15:40 +01:00
|
|
|
/home/joinmarket/menu.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
;;
|
|
|
|
|
PAYJOIN)
|
|
|
|
|
/home/joinmarket/menu.payjoin.sh
|
2020-08-15 15:15:40 +01:00
|
|
|
/home/joinmarket/menu.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
;;
|
|
|
|
|
OFFERS)
|
2020-10-27 15:07:16 +00:00
|
|
|
/home/joinmarket/menu.orderbook.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
/home/joinmarket/menu.sh
|
|
|
|
|
;;
|
|
|
|
|
CONFIG)
|
2021-02-09 17:05:39 +00:00
|
|
|
/home/joinmarket/menu.config.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
echo "Returning to the menu..."
|
|
|
|
|
sleep 1
|
|
|
|
|
/home/joinmarket/menu.sh
|
|
|
|
|
;;
|
2020-12-14 20:04:37 +00:00
|
|
|
TOOLS)
|
|
|
|
|
/home/joinmarket/menu.tools.sh
|
|
|
|
|
/home/joinmarket/menu.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
;;
|
|
|
|
|
UPDATE)
|
2020-09-09 11:20:41 +01:00
|
|
|
/home/joinmarket/menu.update.sh
|
2020-06-21 01:03:29 +01:00
|
|
|
/home/joinmarket/menu.sh
|
|
|
|
|
;;
|
|
|
|
|
X)
|
|
|
|
|
clear
|
|
|
|
|
echo "
|
|
|
|
|
***************************
|
|
|
|
|
* JoinMarket command line *
|
|
|
|
|
***************************
|
2020-06-19 12:40:50 +01:00
|
|
|
Notes on usage:
|
|
|
|
|
https://github.com/openoms/bitcoin-tutorials/blob/master/joinmarket/README.md
|
|
|
|
|
|
|
|
|
|
To open JoininBox menu use: menu
|
|
|
|
|
To exit to the RaspiBlitz menu use: exit
|
|
|
|
|
"
|
2020-09-20 08:27:08 +01:00
|
|
|
exit 0
|
|
|
|
|
;;
|
2020-01-22 22:24:21 +00:00
|
|
|
esac
|