From e124c555d1a889055ddb1426163d24652cc281b4 Mon Sep 17 00:00:00 2001 From: drelbszoomer <173870110+drelbszoomer@users.noreply.github.com> Date: Thu, 22 Aug 2024 11:07:50 -0400 Subject: [PATCH] Default to "wide" get (#135) --- kubel.el | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/kubel.el b/kubel.el index a09bce1..9447676 100644 --- a/kubel.el +++ b/kubel.el @@ -226,6 +226,15 @@ :type 'integer :group 'kubel) +(defcustom kubel-list-wide nil + "Control whether list views show additional colums. + +true - use '-o wide' for list views to show additional columns +false - do not use '-o wide' for list views, hiding additional columns" + :type 'boolean + :group 'kubel) + + (defcustom kubel-use-namespace-list 'auto "Control behavior for namespace completion. @@ -336,7 +345,7 @@ CMD is the command string to run." (defun kubel--populate-list () "Return a list with a tabulated list format and \"tabulated-list-entries\"." - (let* ((body (kubel--exec-to-string (concat (kubel--get-command-prefix) " get " kubel-resource))) + (let* ((body (kubel--exec-to-string (concat (kubel--get-command-prefix) " get " kubel-resource (if kubel-list-wide " -o wide" "")))) (entrylist (kubel--parse-body body))) (when (string-prefix-p "No resources found" body) (message "No resources found")) ;; TODO exception here