Refactoring commands. Connection only needed for install/uninstall.

Signed-off-by: Jason Lewis <jason.lewis1991@gmail.com>