diff --git a/cmd/cirrus/main.go b/cmd/cirrus/main.go index df9273fb..964f3667 100644 --- a/cmd/cirrus/main.go +++ b/cmd/cirrus/main.go @@ -1,12 +1,12 @@ package main import ( - "github.com/cirruslabs/cirrus-cli/internal/cmd" + "github.com/cirruslabs/cirrus-cli/internal/commands" "log" ) func main() { - if err := cmd.NewRootCmd().Execute(); err != nil { + if err := commands.NewRootCmd().Execute(); err != nil { log.Fatal(err) } } diff --git a/internal/cmd/root.go b/internal/commands/root.go similarity index 91% rename from internal/cmd/root.go rename to internal/commands/root.go index e0753a9e..03021e04 100644 --- a/internal/cmd/root.go +++ b/internal/commands/root.go @@ -1,4 +1,4 @@ -package cmd +package commands import "github.com/spf13/cobra" diff --git a/internal/cmd/validate.go b/internal/commands/validate.go similarity index 97% rename from internal/cmd/validate.go rename to internal/commands/validate.go index 2fc96d66..7f0d20bf 100644 --- a/internal/cmd/validate.go +++ b/internal/commands/validate.go @@ -1,4 +1,4 @@ -package cmd +package commands import ( "errors" diff --git a/internal/cmd/validate_test.go b/internal/commands/validate_test.go similarity index 88% rename from internal/cmd/validate_test.go rename to internal/commands/validate_test.go index 3370f9d6..51419297 100644 --- a/internal/cmd/validate_test.go +++ b/internal/commands/validate_test.go @@ -1,7 +1,7 @@ -package cmd_test +package commands_test import ( - "github.com/cirruslabs/cirrus-cli/internal/cmd" + "github.com/cirruslabs/cirrus-cli/internal/commands" "github.com/stretchr/testify/assert" "io/ioutil" "os" @@ -38,7 +38,7 @@ func tempChdir(t *testing.T) { func TestValidateNoArgsNoFile(t *testing.T) { tempChdir(t) - command := cmd.NewRootCmd() + command := commands.NewRootCmd() command.SetArgs([]string{"validate", ""}) err := command.Execute() @@ -52,7 +52,7 @@ func TestValidateNoArgsHasFile(t *testing.T) { t.Fatal(err) } - command := cmd.NewRootCmd() + command := commands.NewRootCmd() command.SetArgs([]string{"validate", ""}) err := command.Execute() @@ -67,7 +67,7 @@ func TestValidateFileArgHasFile(t *testing.T) { t.Fatal(err) } - command := cmd.NewRootCmd() + command := commands.NewRootCmd() command.SetArgs([]string{"validate", "-f", "custom.yml"}) err := command.Execute()