Documentation ¶
Overview ¶
The publish/cmd package implement command line interface for publish. It use config file for each publisher.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var RootCmd = &cobra.Command{ Use: "publish", Short: "Publish document to web services.", Long: `Publish is a document publisher for multible web services in Golang. This application is a tool for a working document to set on web services. Project is available at http://github.com/ynishi/publish`, Run: func(cmd *cobra.Command, args []string) { log.Print("start root command") r, err := os.Open(content) if err != nil { fmt.Println(err) } publish.SetReader(r) publish.SetTimeout(time.Duration(timeout) * time.Second) pas3 := &publish.PublishAwsS3{} pgh := &publish.PublishGitHub{} err = publish.InitConfAwsS3(pas3, aS3Conf) if err != nil { fmt.Println(err) } err = publish.InitConfGitHub(pgh, ghConf) if err != nil { fmt.Println(err) } publishers := []publish.Publisher{ pgh, pas3, } err = publish.Publish(publishers) if err != nil { fmt.Println(err) } log.Print("end root command") }, }
RootCmd is root command.
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.