mirror of
https://github.com/documize/community.git
synced 2025-08-08 06:55:28 +02:00
catch error in SDK documize command
This commit is contained in:
parent
936b68850e
commit
f462631f83
1 changed files with 6 additions and 3 deletions
|
@ -1,11 +1,11 @@
|
||||||
// Copyright 2016 Documize Inc. <legal@documize.com>. All rights reserved.
|
// Copyright 2016 Documize Inc. <legal@documize.com>. All rights reserved.
|
||||||
//
|
//
|
||||||
// This software (Documize Community Edition) is licensed under
|
// This software (Documize Community Edition) is licensed under
|
||||||
// GNU AGPL v3 http://www.gnu.org/licenses/agpl-3.0.en.html
|
// GNU AGPL v3 http://www.gnu.org/licenses/agpl-3.0.en.html
|
||||||
//
|
//
|
||||||
// You can operate outside the AGPL restrictions by purchasing
|
// You can operate outside the AGPL restrictions by purchasing
|
||||||
// Documize Enterprise Edition and obtaining a commercial license
|
// Documize Enterprise Edition and obtaining a commercial license
|
||||||
// by contacting <sales@documize.com>.
|
// by contacting <sales@documize.com>.
|
||||||
//
|
//
|
||||||
// https://documize.com
|
// https://documize.com
|
||||||
|
|
||||||
|
@ -30,7 +30,10 @@ func main() {
|
||||||
flagSet.String("folder", "", "the Documize folder to use"),
|
flagSet.String("folder", "", "the Documize folder to use"),
|
||||||
flagSet.String("action", "load", "the Documize action to take")
|
flagSet.String("action", "load", "the Documize action to take")
|
||||||
|
|
||||||
flagSet.Parse(os.Args[1:])
|
if err := flagSet.Parse(os.Args[1:]); err != nil {
|
||||||
|
fmt.Println("unable to parse Documize arguments:", err)
|
||||||
|
os.Exit(1)
|
||||||
|
}
|
||||||
|
|
||||||
if *url == "" {
|
if *url == "" {
|
||||||
fmt.Println("Please set the environment variable DOCUMIZEAPI or use the -api flag")
|
fmt.Println("Please set the environment variable DOCUMIZEAPI or use the -api flag")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue