cmd/lncli: move commands and export

We want to export some of our CLI code to re-use in other projects. But
in Golang you cannot import code from a `main` package.
So we need to move the actual code into its own package and only have
the `func main()` in the `main` package.
This commit is contained in:
Oliver Gugger committed 2024-08-23 10:57:59 +02:00
1 parent 75477c8896
commit 22a3988222
43 files changed
+841 -674

No files matched your search

+17
View File
@@ -0,0 +1,17 @@
package commands
import "github.com/urfave/cli"
// routerCommands returns a list of routerrpc commands.
func routerCommands() []cli.Command {
return []cli.Command{
queryMissionControlCommand,
importMissionControlCommand,
queryProbCommand,
resetMissionControlCommand,
buildRouteCommand,
getCfgCommand,
setCfgCommand,
updateChanStatusCommand,
}
}