mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 03:41:45 +00:00
kubectl: Use Fprintf
Signed-off-by: Gaurav Singh <gaurav1086@gmail.com> Fix typo Signed-off-by: Gaurav Singh <gaurav1086@gmail.com> Change Fprintf to Fprintln Signed-off-by: Gaurav Singh <gaurav1086@gmail.com> Use %q instead of %s Signed-off-by: Gaurav Singh <gaurav1086@gmail.com> Change %q to %s
This commit is contained in:
parent
4e8b56e667
commit
b326948a9a
@ -586,9 +586,9 @@ func (o *GetOptions) Run(f cmdutil.Factory, cmd *cobra.Command, args []string) e
|
||||
if trackingWriter.Written == 0 && !o.IgnoreNotFound && len(allErrs) == 0 {
|
||||
// if we wrote no output, and had no errors, and are not ignoring NotFound, be sure we output something
|
||||
if allResourcesNamespaced {
|
||||
fmt.Fprintln(o.ErrOut, fmt.Sprintf("No resources found in %s namespace.", o.Namespace))
|
||||
fmt.Fprintf(o.ErrOut, "No resources found in %s namespace.\n", o.Namespace)
|
||||
} else {
|
||||
fmt.Fprintln(o.ErrOut, fmt.Sprintf("No resources found"))
|
||||
fmt.Fprintln(o.ErrOut, "No resources found")
|
||||
}
|
||||
}
|
||||
return utilerrors.NewAggregate(allErrs)
|
||||
|
Loading…
Reference in New Issue
Block a user