Пример #1
0
/*
* Unlike most Go programs, the `Main()` function will not be used to run all of the
* commands provided in your plugin. Main will be used to initialize the plugin
* process, as well as any dependencies you might require for your
* plugin.
 */
func main() {
	// Any initialization for your plugin can be handled here
	//
	// Note: to run the plugin.Start method, we pass in a pointer to the struct
	// implementing the interface defined at "github.com/nttlabs/cli/plugin/plugin.go"
	//
	// Note: The plugin's main() method is invoked at install time to collect
	// metadata. The plugin will exit 0 and the Run([]string) method will not be
	// invoked.
	plugin.Start(new(BasicPlugin))
	// Plugin code should be written in the Run([]string) method,
	// ensuring the plugin environment is bootstrapped.
}
Пример #2
0
func main() {
	plugin.Start(new(Test1))
}
Пример #3
0
func main() {
	plugin.Start(new(TestWithPushShortName))
}
Пример #4
0
func main() {
	plugin.Start(new(PluginDemonstratingParams))
}
Пример #5
0
func main() {
	plugin.Start(new(TestWithPush))
}
Пример #6
0
func main() {
	plugin.Start(new(MySay))
}
Пример #7
0
func main() {
	plugin.Start(new(TestWithHelp))
}
Пример #8
0
func main() {
	plugin.Start(new(Input))
}
Пример #9
0
func main() {
	plugin.Start(new(Interactive))
}
Пример #10
0
func main() {
	plugin.Start(new(EmptyPlugin))
}
Пример #11
0
func main() {
	plugin.Start(new(CoreCmd))
}
Пример #12
0
func main() {
	plugin.Start(new(CliCmd))
}
Пример #13
0
func main() {
	plugin.Start(new(Panics))
}