Skip to content

Commit

Permalink
Move cmd/internal to subpackage
Browse files Browse the repository at this point in the history
Signed-off-by: apostasie <[email protected]>
  • Loading branch information
apostasie committed Sep 2, 2024
1 parent c115c49 commit d5a00f4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions cmd/nerdctl/internal.go → cmd/nerdctl/internal/internal.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
limitations under the License.
*/

package main
package internal

import (
"github.com/spf13/cobra"
)

func newInternalCommand() *cobra.Command {
func NewInternalCommand() *cobra.Command {
var internalCommand = &cobra.Command{
Use: "internal",
Short: "DO NOT EXECUTE MANUALLY",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
limitations under the License.
*/

package main
package internal

import (
"errors"
Expand Down
3 changes: 2 additions & 1 deletion cmd/nerdctl/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import (
"github.com/containerd/nerdctl/v2/cmd/nerdctl/completion"
"github.com/containerd/nerdctl/v2/cmd/nerdctl/helpers"
"github.com/containerd/nerdctl/v2/cmd/nerdctl/image"
"github.com/containerd/nerdctl/v2/cmd/nerdctl/internal"
"github.com/containerd/nerdctl/v2/cmd/nerdctl/ipfs"
"github.com/containerd/nerdctl/v2/cmd/nerdctl/login"
"github.com/containerd/nerdctl/v2/cmd/nerdctl/namespace"
Expand Down Expand Up @@ -305,7 +306,7 @@ Config file ($NERDCTL_TOML): %s
// #endregion

// Internal
newInternalCommand(),
internal.NewInternalCommand(),

// login
login.NewLoginCommand(),
Expand Down

0 comments on commit d5a00f4

Please sign in to comment.