aboutsummaryrefslogtreecommitdiff
path: root/config/init.go
diff options
context:
space:
mode:
authorJulien Dessaux2020-02-24 23:05:45 +0100
committerJulien Dessaux2020-02-25 09:46:38 +0100
commitcadb15f7afb5e7c88667eb4006209efca17744af (patch)
tree7e8e9e55c22bd4d195caf2b1dc1123500443ce75 /config/init.go
parentAdded tests to the spool package, and reworked the code around that. (diff)
downloadbareos-zabbix-check-cadb15f7afb5e7c88667eb4006209efca17744af.tar.gz
bareos-zabbix-check-cadb15f7afb5e7c88667eb4006209efca17744af.tar.bz2
bareos-zabbix-check-cadb15f7afb5e7c88667eb4006209efca17744af.zip
Added tests to the main package and completely reworked the code around that1.0
Diffstat (limited to '')
-rw-r--r--config/init.go16
1 files changed, 0 insertions, 16 deletions
diff --git a/config/init.go b/config/init.go
deleted file mode 100644
index f737fb3..0000000
--- a/config/init.go
+++ /dev/null
@@ -1,16 +0,0 @@
-package config
-
-import "flag"
-
-// Init initialises a program config from the command line flags
-func (c *Config) Init() {
- flag.BoolVar(&c.verbose, "v", false, "Activates verbose debugging output, defaults to false.")
- flag.BoolVar(&c.quiet, "q", false, "Suppress all output, suitable to force a silent update of the spool file.")
- flag.StringVar(&c.stateFile, "f", "", "Force the state file to use, defaults to "+bareosStateFile+" if it exists else "+baculaStateFile+".")
- flag.StringVar(&c.workDir, "w", "", "Force the work directory to use, defaults to "+bareosWorkDir+" if it exists else "+baculaWorkDir+".")
-
- // command line arguments parsing
- flag.Parse()
- c.checkWorkDir()
- c.checkStateFile()
-}