Skip to content

Commit

Permalink
Make changes more user friendly while retaining ability to use env va…
Browse files Browse the repository at this point in the history
…riables
  • Loading branch information
sblackstone committed Jun 26, 2019
1 parent bf6576f commit 7a0b436
Show file tree
Hide file tree
Showing 2 changed files with 62 additions and 26 deletions.
45 changes: 32 additions & 13 deletions resources/gatewaystart.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,23 @@
#=============================================================================+


TWS_MAJOR_VRSN=${TWS_MAJOR_VRSN:-972}
IBC_INI=${IBC_INI:-"${HOME}/ibc/config.ini"}
TRADING_MODE=${TRADING_MODE:-""}
IBC_PATH=${IBC_PATH:-"/opt/ibc"}
TWS_PATH=${TWS_PATH:-"${HOME}/Jts"}
TWS_SETTINGS_PATH=${TWS_SETTINGS_PATH:-""}
LOG_PATH=${LOG_PATH:-"${HOME}/ibc/logs"}
TWSUSERID=${TWSUSERID:-""}
TWSPASSWORD=${TWSPASSWORD:-""}
FIXUSERID=${FIXUSERID:-""}
FIXPASSWORD=${FIXPASSWORD:-""}
JAVA_PATH=${JAVA_PATH:-""}
HIDE=${HIDE:-""}
# To set one of these, remove the # in the front of the line.

#TWS_MAJOR_VRSN=972
#IBC_INI=~/ibc/config.ini
#TRADING_MODE=
#IBC_PATH=/opt/ibc
#TWS_PATH=~/Jts
#TWS_SETTINGS_PATH=
#LOG_PATH=~/ibc/logs
#TWSUSERID=
#TWSPASSWORD=
#FIXUSERID=
#FIXPASSWORD=
#JAVA_PATH=
#HIDE=




# PLEASE DON'T CHANGE ANYTHING BELOW THIS LINE !!
Expand Down Expand Up @@ -160,6 +164,21 @@ fi

APP=GATEWAY

# Ensure we have settings for everything..
TWS_MAJOR_VRSN=${TWS_MAJOR_VRSN:-972}
IBC_INI=${IBC_INI:-"${HOME}/ibc/config.ini"}
TRADING_MODE=${TRADING_MODE:-""}
IBC_PATH=${IBC_PATH:-"/opt/ibc"}
TWS_PATH=${TWS_PATH:-"${HOME}/Jts"}
TWS_SETTINGS_PATH=${TWS_SETTINGS_PATH:-""}
LOG_PATH=${LOG_PATH:-"${HOME}/ibc/logs"}
TWSUSERID=${TWSUSERID:-""}
TWSPASSWORD=${TWSPASSWORD:-""}
FIXUSERID=${FIXUSERID:-""}
FIXPASSWORD=${FIXPASSWORD:-""}
JAVA_PATH=${JAVA_PATH:-""}
HIDE=${HIDE:-""}

export TWS_MAJOR_VRSN
export IBC_INI
export TRADING_MODE
Expand Down
43 changes: 30 additions & 13 deletions resources/gatewaystartmacos.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,21 @@
#=============================================================================+


TWS_MAJOR_VRSN=${TWS_MAJOR_VRSN:-972}
IBC_INI=${IBC_INI:-"${HOME}/ibc/config.ini"}
TRADING_MODE=${TRADING_MODE:-""}
IBC_PATH=${IBC_PATH:-"/opt/ibc"}
TWS_PATH=${TWS_PATH:-"${HOME}/Jts"}
TWS_SETTINGS_PATH=${TWS_SETTINGS_PATH:-""}
LOG_PATH=${LOG_PATH:-"${HOME}/ibc/logs"}
TWSUSERID=${TWSUSERID:-""}
TWSPASSWORD=${TWSPASSWORD:-""}
FIXUSERID=${FIXUSERID:-""}
FIXPASSWORD=${FIXPASSWORD:-""}
JAVA_PATH=${JAVA_PATH:-""}
HIDE=${HIDE:-""}
# To set one of these, remove the # in the front of the line.

#TWS_MAJOR_VRSN=972
#IBC_INI=~/ibc/config.ini
#TRADING_MODE=
#IBC_PATH=/opt/ibc
#TWS_PATH=~/Jts
#TWS_SETTINGS_PATH=
#LOG_PATH=~/ibc/logs
#TWSUSERID=
#TWSPASSWORD=
#FIXUSERID=
#FIXPASSWORD=
#JAVA_PATH=
#HIDE=


# PLEASE DON'T CHANGE ANYTHING BELOW THIS LINE !!
Expand Down Expand Up @@ -142,6 +144,21 @@ HIDE=${HIDE:-""}

APP=GATEWAY

# Ensure we have settings for everything..
TWS_MAJOR_VRSN=${TWS_MAJOR_VRSN:-972}
IBC_INI=${IBC_INI:-"${HOME}/ibc/config.ini"}
TRADING_MODE=${TRADING_MODE:-""}
IBC_PATH=${IBC_PATH:-"/opt/ibc"}
TWS_PATH=${TWS_PATH:-"${HOME}/Jts"}
TWS_SETTINGS_PATH=${TWS_SETTINGS_PATH:-""}
LOG_PATH=${LOG_PATH:-"${HOME}/ibc/logs"}
TWSUSERID=${TWSUSERID:-""}
TWSPASSWORD=${TWSPASSWORD:-""}
FIXUSERID=${FIXUSERID:-""}
FIXPASSWORD=${FIXPASSWORD:-""}
JAVA_PATH=${JAVA_PATH:-""}
HIDE=${HIDE:-""}

export TWS_MAJOR_VRSN
export IBC_INI
export TRADING_MODE
Expand Down

0 comments on commit 7a0b436

Please sign in to comment.