mirror of
https://github.com/fluxcd/flux2.git
synced 2026-05-04 09:08:51 +00:00
Refactor all remaining create, delete, export, get command to use adapter
Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
This commit is contained in:
parent
c23e8c7ee1
commit
465eaa24d3
28 changed files with 513 additions and 1043 deletions
|
|
@ -20,7 +20,6 @@ import (
|
|||
"bytes"
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/spf13/cobra"
|
||||
"k8s.io/apimachinery/pkg/types"
|
||||
"sigs.k8s.io/controller-runtime/pkg/client"
|
||||
|
|
@ -86,8 +85,7 @@ func (export exportCommand) run(cmd *cobra.Command, args []string) error {
|
|||
}
|
||||
|
||||
if export.list.len() == 0 {
|
||||
logger.Failuref("no objects found in %s namespace", rootArgs.namespace)
|
||||
return nil
|
||||
return fmt.Errorf("no objects found in %s namespace", rootArgs.namespace)
|
||||
}
|
||||
|
||||
for i := 0; i < export.list.len(); i++ {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue