I want to hide all Dired buffers as major mode in Ibuffer.
(add-to-list 'ibuffer-never-show-predicates "magit*")
ibuffer-never-show-predicates accepts a regexp and a function.
How can I hide all Dired buffers in Ibuffer?
Yes, you can write a predicate function for that:
(defun my-dired-mode-buffer-p (buf) "Non-nil if buffer BUF is in `dired-mode'." (with-current-buffer buf (derived-mode-p 'dired-mode))) (with-eval-after-load "ibuffer" (add-to-list 'ibuffer-never-show-predicates #'my-dired-mode-buffer-p))