// Define your command setclass MyCommandSet {
\@command
def hello = println("hello")
\@command
def world = println("world")
}
// Integrate the above command set as a module with a given name.// Command can be invoked as "sample hello" and "sample world".class MyModule extends CommandModule {
def modules = Seq(ModuleDef[MyCommandSet]("sample", description="my command set"))
}
Launcher[MyModule].execute("sample hello") // prints hello