github.com/buildpacks/pack@v0.33.3-0.20240516162812-884dd1837311/internal/commands/list_registries.go (about)

     1  package commands
     2  
     3  import (
     4  	"github.com/spf13/cobra"
     5  
     6  	"github.com/buildpacks/pack/internal/config"
     7  	"github.com/buildpacks/pack/pkg/logging"
     8  )
     9  
    10  // Deprecated: Use config registries list instead
    11  func ListBuildpackRegistries(logger logging.Logger, cfg config.Config) *cobra.Command {
    12  	cmd := &cobra.Command{
    13  		Use:     "list-registries",
    14  		Args:    cobra.NoArgs,
    15  		Hidden:  true,
    16  		Short:   "List buildpack registries",
    17  		Example: "pack list-registries",
    18  		RunE: logError(logger, func(cmd *cobra.Command, args []string) error {
    19  			deprecationWarning(logger, "list-registries", "config registries list")
    20  			listRegistries(args, logger, cfg)
    21  
    22  			return nil
    23  		}),
    24  	}
    25  
    26  	return cmd
    27  }