refactor(commands): extract commands to own module
This commit is contained in:
parent
e33237ca74
commit
8b2b27961e
3 changed files with 4 additions and 3 deletions
|
@ -1,4 +1,4 @@
|
||||||
package main
|
package commands
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"maps"
|
"maps"
|
|
@ -1,4 +1,4 @@
|
||||||
package main
|
package commands
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
3
v.go
3
v.go
|
@ -3,6 +3,7 @@ package main
|
||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
cli "v/cli"
|
cli "v/cli"
|
||||||
|
commands "v/commands"
|
||||||
python "v/python"
|
python "v/python"
|
||||||
state "v/state"
|
state "v/state"
|
||||||
)
|
)
|
||||||
|
@ -20,7 +21,7 @@ func main() {
|
||||||
|
|
||||||
root := cli.Namespace{Label: ""}
|
root := cli.Namespace{Label: ""}
|
||||||
root.AddCommand(
|
root.AddCommand(
|
||||||
"init", Initialize, "v init", "Initializes the v state.",
|
"init", commands.Initialize, "v init", "Initializes the v state.",
|
||||||
)
|
)
|
||||||
|
|
||||||
cli := cli.CLI{
|
cli := cli.CLI{
|
||||||
|
|
Loading…
Reference in a new issue