Add kubernetes-sort-custom-column-print-flags.patch for reproducible builds OBS-URL: https://build.opensuse.org/request/show/1137979 OBS-URL: https://build.opensuse.org/package/show/devel:kubic/kubernetes1.22?expand=0&rev=20
34 lines
1000 B
Diff
34 lines
1000 B
Diff
From 0a594d9c858958078463954d10bfc17736910da9 Mon Sep 17 00:00:00 2001
|
|
From: kkkkun <scuzk373x@gmail.com>
|
|
Date: Thu, 3 Mar 2022 22:31:58 +0800
|
|
Subject: [PATCH] sort custom column print flags
|
|
|
|
(cherry picked from commit 36ed148761cb5a30c21b45a64d95cabd1a9d07ff)
|
|
---
|
|
staging/src/k8s.io/kubectl/pkg/cmd/get/customcolumn_flags.go | 2 ++
|
|
1 file changed, 2 insertions(+)
|
|
|
|
diff --git a/staging/src/k8s.io/kubectl/pkg/cmd/get/customcolumn_flags.go b/staging/src/k8s.io/kubectl/pkg/cmd/get/customcolumn_flags.go
|
|
index eee919b49b3..efd7fcf7524 100644
|
|
--- a/staging/src/k8s.io/kubectl/pkg/cmd/get/customcolumn_flags.go
|
|
+++ b/staging/src/k8s.io/kubectl/pkg/cmd/get/customcolumn_flags.go
|
|
@@ -19,6 +19,7 @@ package get
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
+ "sort"
|
|
"strings"
|
|
|
|
"github.com/spf13/cobra"
|
|
@@ -45,6 +46,7 @@ func (f *CustomColumnsPrintFlags) AllowedFormats() []string {
|
|
for format := range columnsFormats {
|
|
formats = append(formats, format)
|
|
}
|
|
+ sort.Strings(formats)
|
|
return formats
|
|
}
|
|
|
|
--
|
|
2.35.3
|
|
|