master > master: code go - refactoring
This commit is contained in:
36
code/golang/internal/endpoints/print/print.go
Normal file
36
code/golang/internal/endpoints/print/print.go
Normal file
@@ -0,0 +1,36 @@
|
||||
package print
|
||||
|
||||
/* ---------------------------------------------------------------- *
|
||||
* IMPORTS
|
||||
* ---------------------------------------------------------------- */
|
||||
|
||||
import (
|
||||
"ads/internal/core/logging"
|
||||
"ads/internal/setup"
|
||||
"ads/internal/setup/cli"
|
||||
)
|
||||
|
||||
/* ---------------------------------------------------------------- *
|
||||
* ENDPOINT version
|
||||
* ---------------------------------------------------------------- */
|
||||
|
||||
func Version() {
|
||||
logging.SetForce(true)
|
||||
logging.LogPlain(setup.Version())
|
||||
}
|
||||
|
||||
/* ---------------------------------------------------------------- *
|
||||
* ENDPOINT help
|
||||
* ---------------------------------------------------------------- */
|
||||
|
||||
func Help() {
|
||||
logging.SetForce(true)
|
||||
cli.ParseCli([]string{}) // <- generiere leere Instanz für Parser, um voll Hilfsanleitug zu zeigen
|
||||
logging.LogPlain(
|
||||
"",
|
||||
setup.Logo(),
|
||||
// setup.Help(),
|
||||
cli.Parser.Usage(nil),
|
||||
"",
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user