From b926acbb65ac78c2802b6481e233ab958f8b339d Mon Sep 17 00:00:00 2001 From: tgic Date: Mon, 29 Dec 2014 22:56:34 +0800 Subject: [PATCH] fix the init order --- sshpiperd/sshpiperd.go | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/sshpiperd/sshpiperd.go b/sshpiperd/sshpiperd.go index 8863f53c..098e6634 100644 --- a/sshpiperd/sshpiperd.go +++ b/sshpiperd/sshpiperd.go @@ -27,19 +27,18 @@ func showHelpOrVersion() { } if config.ShowVersion { - showVersion() os.Exit(0) } } func main() { - - showHelpOrVersion() - - showVersion() initConfig() initTemplate() initLogger() + + showVersion() + showHelpOrVersion() + showConfig() // TODO make this pluggable