mirror of
https://github.com/containers/podman.git
synced 2025-10-17 11:14:40 +08:00
lint: reenable revive unused-parameter check
Signed-off-by: Matt Souza <medsouz99@gmail.com>
This commit is contained in:
@ -88,7 +88,7 @@ func init() {
|
||||
flags.StringVarP(&createContainerOpts.Layer, "layer", "l", "", "ID of containers's read-write layer (default none)")
|
||||
}
|
||||
|
||||
func createStorageLayer(cmd *cobra.Command, args []string) error {
|
||||
func createStorageLayer(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.CreateStorageLayer(mainContext, createStorageLayerOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
@ -98,7 +98,7 @@ func createStorageLayer(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func createLayer(cmd *cobra.Command, args []string) error {
|
||||
func createLayer(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.CreateLayer(mainContext, createLayerOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
@ -108,7 +108,7 @@ func createLayer(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func createImage(cmd *cobra.Command, args []string) error {
|
||||
func createImage(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.CreateImage(mainContext, createImageOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
@ -118,7 +118,7 @@ func createImage(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func createContainer(cmd *cobra.Command, args []string) error {
|
||||
func createContainer(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.CreateContainer(mainContext, createContainerOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
|
@ -205,7 +205,7 @@ func init() {
|
||||
flags.StringVarP(&removeContainerDataOpts.Key, "key", "k", "", "Name of the data item")
|
||||
}
|
||||
|
||||
func createLayerData(cmd *cobra.Command, args []string) error {
|
||||
func createLayerData(_ *cobra.Command, _ []string) error {
|
||||
if createLayerDataOpts.ID == "" {
|
||||
return errors.New("layer ID not specified")
|
||||
}
|
||||
@ -233,7 +233,7 @@ func createLayerData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func createImageData(cmd *cobra.Command, args []string) error {
|
||||
func createImageData(_ *cobra.Command, _ []string) error {
|
||||
if createImageDataOpts.ID == "" {
|
||||
return errors.New("image ID not specified")
|
||||
}
|
||||
@ -261,7 +261,7 @@ func createImageData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func createContainerData(cmd *cobra.Command, args []string) error {
|
||||
func createContainerData(_ *cobra.Command, _ []string) error {
|
||||
if createContainerDataOpts.ID == "" {
|
||||
return errors.New("container ID not specified")
|
||||
}
|
||||
@ -289,7 +289,7 @@ func createContainerData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func modifyLayerData(cmd *cobra.Command, args []string) error {
|
||||
func modifyLayerData(_ *cobra.Command, _ []string) error {
|
||||
if modifyLayerDataOpts.ID == "" {
|
||||
return errors.New("layer ID not specified")
|
||||
}
|
||||
@ -314,7 +314,7 @@ func modifyLayerData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func modifyImageData(cmd *cobra.Command, args []string) error {
|
||||
func modifyImageData(_ *cobra.Command, _ []string) error {
|
||||
if modifyImageDataOpts.ID == "" {
|
||||
return errors.New("image ID not specified")
|
||||
}
|
||||
@ -339,7 +339,7 @@ func modifyImageData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func modifyContainerData(cmd *cobra.Command, args []string) error {
|
||||
func modifyContainerData(_ *cobra.Command, _ []string) error {
|
||||
if modifyContainerDataOpts.ID == "" {
|
||||
return errors.New("container ID not specified")
|
||||
}
|
||||
@ -364,7 +364,7 @@ func modifyContainerData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func removeLayerData(cmd *cobra.Command, args []string) error {
|
||||
func removeLayerData(_ *cobra.Command, _ []string) error {
|
||||
if removeLayerDataOpts.ID == "" {
|
||||
return errors.New("layer ID not specified")
|
||||
}
|
||||
@ -378,7 +378,7 @@ func removeLayerData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func removeImageData(cmd *cobra.Command, args []string) error {
|
||||
func removeImageData(_ *cobra.Command, _ []string) error {
|
||||
if removeImageDataOpts.ID == "" {
|
||||
return errors.New("image ID not specified")
|
||||
}
|
||||
@ -392,7 +392,7 @@ func removeImageData(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func removeContainerData(cmd *cobra.Command, args []string) error {
|
||||
func removeContainerData(_ *cobra.Command, _ []string) error {
|
||||
if removeContainerDataOpts.ID == "" {
|
||||
return errors.New("container ID not specified")
|
||||
}
|
||||
|
@ -54,7 +54,7 @@ func init() {
|
||||
flags.StringVarP(&modifyLayerFile, "file", "f", "", "archive of contents to extract over layer")
|
||||
}
|
||||
|
||||
func populateLayer(cmd *cobra.Command, args []string) error {
|
||||
func populateLayer(_ *cobra.Command, _ []string) error {
|
||||
if populateLayerOpts.ID == "" {
|
||||
return errors.New("layer ID not specified")
|
||||
}
|
||||
@ -73,7 +73,7 @@ func populateLayer(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func modifyLayer(cmd *cobra.Command, args []string) error {
|
||||
func modifyLayer(_ *cobra.Command, _ []string) error {
|
||||
if modifyLayerOpts.ID == "" {
|
||||
return errors.New("layer ID not specified")
|
||||
}
|
||||
|
@ -26,13 +26,13 @@ var (
|
||||
mainCmd = &cobra.Command{
|
||||
Use: "podman-testing",
|
||||
Long: "Assorted tools for use in testing podman",
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
RunE: func(cmd *cobra.Command, _ []string) error {
|
||||
return cmd.Help()
|
||||
},
|
||||
PersistentPreRunE: func(cmd *cobra.Command, args []string) error {
|
||||
PersistentPreRunE: func(_ *cobra.Command, _ []string) error {
|
||||
return before()
|
||||
},
|
||||
PersistentPostRunE: func(cmd *cobra.Command, args []string) error {
|
||||
PersistentPostRunE: func(_ *cobra.Command, _ []string) error {
|
||||
return after()
|
||||
},
|
||||
SilenceUsage: true,
|
||||
|
@ -83,7 +83,7 @@ func init() {
|
||||
flags.StringVarP(&removeContainerOpts.ID, "container", "i", "", "ID of the container to remove")
|
||||
}
|
||||
|
||||
func removeStorageLayer(cmd *cobra.Command, args []string) error {
|
||||
func removeStorageLayer(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.RemoveStorageLayer(mainContext, removeStorageLayerOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
@ -92,7 +92,7 @@ func removeStorageLayer(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func removeLayer(cmd *cobra.Command, args []string) error {
|
||||
func removeLayer(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.RemoveLayer(mainContext, removeLayerOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
@ -101,7 +101,7 @@ func removeLayer(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func removeImage(cmd *cobra.Command, args []string) error {
|
||||
func removeImage(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.RemoveImage(mainContext, removeImageOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
@ -110,7 +110,7 @@ func removeImage(cmd *cobra.Command, args []string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func removeContainer(cmd *cobra.Command, args []string) error {
|
||||
func removeContainer(_ *cobra.Command, _ []string) error {
|
||||
results, err := testingEngine.RemoveContainer(mainContext, removeContainerOpts)
|
||||
if err != nil {
|
||||
return err
|
||||
|
Reference in New Issue
Block a user