Goldengate Microservices architecture replaced the “ggsci” tool with “adminclient”. This new client has few limitations and does not work well with “rlwrap” – my favorite tool to have history between sessions.
The Adminclient provides some options you can easily change after starting the tool:
$ ./adminclient
...
OGG (not connected) 1> show
Current directory: /home/oracle
COLOR : OFF
DEBUG : OFF
EDITOR : vi
PAGER : more
VERBOSE : OFF
OGG (not connected) 2> set color ON
OGG (not connected) 3> set pager less
OGG (not connected) 4> show
Current directory: /home/oracle
COLOR : ON
DEBUG : OFF
EDITOR : vi
PAGER : less
VERBOSE : OFF
However to keep the settings across sessions it is not very straight forward. The way to do it is to set variables:
$ export ADMINCLIENT_COLOR=ON # ON, OFF in uppercase!
And ADMINCLIENT_DEBUG and ADMINCLIENT_VERBOSE for DEBUG and VERBOSE respectively
For the editor and pager, the variables are simply:
export EDITOR=nano
export PAGER=less
Attention that the variable EDITOR is used also by other clients, like sqlplus “edit” command.
So the way I do it, is to set everything within an alias:
alias gg="cd $OGG_HOME/bin; EDITOR=nano PAGER=less ADMINCLIENT_COLOR=ON $RLWRAP ./adminclient ; cd -"
And inside .bash_profile or something that sets the environment:
RLWRAP="$(command -v rlwrap)" && RLWRAP="${RLWRAP} -c"
export OGG_HOME="/u00/app/oracle/product/ogg/21.15"
alias gg="cd $OGG_HOME/bin; EDITOR=nano PAGER=less ADMINCLIENT_COLOR=ON $RLWRAP ./adminclient ; cd -"