Skip to content

Commit

Permalink
Default to "wide" get (abrochard#135)
Browse files Browse the repository at this point in the history
  • Loading branch information
drelbszoomer authored Aug 22, 2024
1 parent 99fc8f1 commit e124c55
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion kubel.el
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down Expand Up @@ -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
Expand Down

0 comments on commit e124c55

Please sign in to comment.