Function: treemacs-advanced-helpful-hydra

treemacs-advanced-helpful-hydra is an autoloaded, interactive and byte-compiled function defined in treemacs-hydras.el.

Signature

(treemacs-advanced-helpful-hydra)

Documentation

Summon a helpful hydra to show you the treemacs keymap.

This hydra will show the more advanced (rarely used) keybinds for treemacs. For the more commonly used keybinds see treemacs-common-helpful-hydra.

The keybinds shown in this hydra are not static, but reflect the actual keybindings currently in use (including evil mode). If the hydra is unable to find the key a command is bound to it will show a blank instead.

Key Bindings

Source Code

;; Defined in ~/.emacs.d/elpa/treemacs-20251226.1307/treemacs-hydras.el
;;;###autoload
(defun treemacs-advanced-helpful-hydra ()
  "Summon a helpful hydra to show you the treemacs keymap.

This hydra will show the more advanced (rarely used) keybinds for treemacs.  For
the more commonly used keybinds see `treemacs-common-helpful-hydra'.

The keybinds shown in this hydra are not static, but reflect the actual
keybindings currently in use (including evil mode).  If the hydra is unable to
find the key a command is bound to it will show a blank instead."
  (interactive)
  (-if-let (b (treemacs-get-local-buffer))
      (with-current-buffer b
        (let*
            ((title              (format (propertize "Treemacs %s Advanced Helpful Hydra" 'face 'treemacs-help-title-face) (treemacs-version)))
             (column-files       (propertize "File Management" 'face 'treemacs-help-column-face))
             (column-ws          (propertize "Workspaces" 'face 'treemacs-help-column-face))
             (column-misc        (propertize "Misc." 'face 'treemacs-help-column-face))
             (column-window      (propertize "Other Window" 'face 'treemacs-help-column-face))
             (common-hint        (format "%s %s"
                                         (propertize "For common keybinds see" 'face 'treemacs-help-title-face)
                                         (propertize "treemacs-common-helpful-hydra" 'face 'font-lock-function-name-face)))
             (key-common-hydra   (treemacs--find-keybind #'treemacs-common-helpful-hydra))
             (key-create-file    (treemacs--find-keybind #'treemacs-create-file))
             (key-create-dir     (treemacs--find-keybind #'treemacs-create-dir))
             (key-rename         (treemacs--find-keybind #'treemacs-rename-file))
             (key-delete         (treemacs--find-keybind #'treemacs-delete-file))
             (key-copy-file      (treemacs--find-keybind #'treemacs-copy-file))
             (key-move-file      (treemacs--find-keybind #'treemacs-move-file))
             (key-refresh        (treemacs--find-keybind #'treemacs-refresh))
             (key-set-width      (treemacs--find-keybind #'treemacs-set-width))
             (key-copy-path-abs  (treemacs--find-keybind #'treemacs-copy-absolute-path-at-point))
             (key-copy-path-rel  (treemacs--find-keybind #'treemacs-copy-relative-path-at-point))
             (key-copy-root      (treemacs--find-keybind #'treemacs-copy-project-path-at-point))
             (key-resort         (treemacs--find-keybind #'treemacs-resort))
             (key-bookmark       (treemacs--find-keybind #'treemacs-add-bookmark))
             (key-edit-ws        (treemacs--find-keybind #'treemacs-edit-workspaces 12))
             (key-create-ws      (treemacs--find-keybind #'treemacs-create-workspace 12))
             (key-remove-ws      (treemacs--find-keybind #'treemacs-remove-workspace 12))
             (key-rename-ws      (treemacs--find-keybind #'treemacs-rename-workspace 12))
             (key-switch-ws      (treemacs--find-keybind #'treemacs-switch-workspace 12))
             (key-next-ws        (treemacs--find-keybind #'treemacs-next-workspace 12))
             (key-fallback-ws    (treemacs--find-keybind #'treemacs-set-fallback-workspace 12))
             (key-peek           (treemacs--find-keybind #'treemacs-peek-mode 10))
             (key-line-down      (treemacs--find-keybind #'treemacs-next-line-other-window 10))
             (key-line-up        (treemacs--find-keybind #'treemacs-previous-line-other-window 10))
             (key-page-down      (treemacs--find-keybind #'treemacs-next-page-other-window 10))
             (key-page-up        (treemacs--find-keybind #'treemacs-previous-page-other-window 10))
             (key-bulk-actions   (treemacs--find-keybind #'treemacs-bulk-file-actions))
             (hydra-str
              (format
               "
%s
%s (%s)

%s      ^^^^^^^^^^^^^│ %s                  ^^^^^^^^│ %s       ^^^^^^^^^^│ %s
―――――――――――――――――――――┼―――――――――――――――――――――――――――――┼――――――――――――――――――――┼――――――――――――――――――――――
 %s create file  ^^^^│ %s Edit Workspaces  ^^^^^^^^│ %s peek      ^^^^^^│ %s refresh
 %s create dir   ^^^^│ %s Create Workspace ^^^^^^^^│ %s line down ^^^^^^│ %s (re)set width
 %s rename       ^^^^│ %s Remove Workspace ^^^^^^^^│ %s line up   ^^^^^^│ %s copy path absolute
 %s delete       ^^^^│ %s Rename Workspace ^^^^^^^^│ %s page down ^^^^^^│ %s copy path relative
 %s copy         ^^^^│ %s Switch Workspace ^^^^^^^^│ %s page up   ^^^^^^│ %s copy root path
 %s move         ^^^^│ %s Next Workspace   ^^^^^^^^│                    │ %s re-sort
 %s bulk actions ^^^^│ %s Set Fallback     ^^^^^^^^│                    │ %s bookmark

"
               title
               common-hint (car (s-split":" (car key-common-hydra)))
               column-files           column-ws             column-window       column-misc
               (car key-create-file)  (car key-edit-ws)     (car key-peek)      (car key-refresh)
               (car key-create-dir)   (car key-create-ws)   (car key-line-down) (car key-set-width)
               (car key-rename)       (car key-remove-ws)   (car key-line-up)   (car key-copy-path-abs)
               (car key-delete)       (car key-rename-ws)   (car key-page-down) (car key-copy-path-rel)
               (car key-copy-file)    (car key-switch-ws)   (car key-page-up)   (car key-copy-root)
               (car key-move-file)    (car key-next-ws)                         (car key-resort)
               (car key-bulk-actions) (car key-fallback-ws)                     (car key-bookmark))))
          (eval
           `(defhydra treemacs--advanced-helpful-hydra (:exit nil :hint nil :columns 3)
              ,hydra-str
              (,(cdr key-common-hydra)   #'treemacs-common-helpful-hydra :exit t)
              (,(cdr key-create-file)    #'treemacs-create-file)
              (,(cdr key-create-dir)     #'treemacs-create-dir)
              (,(cdr key-rename)         #'treemacs-rename-file)
              (,(cdr key-delete)         #'treemacs-delete-file)
              (,(cdr key-copy-file)      #'treemacs-copy-file)
              (,(cdr key-move-file)      #'treemacs-move-file)
              (,(cdr key-refresh)        #'treemacs-refresh)
              (,(cdr key-set-width)      #'treemacs-set-width)
              (,(cdr key-copy-path-rel)  #'treemacs-copy-absolute-path-at-point)
              (,(cdr key-copy-path-abs)  #'treemacs-copy-relative-path-at-point)
              (,(cdr key-copy-root)      #'treemacs-copy-project-path-at-point)
              (,(cdr key-resort)         #'treemacs-resort)
              (,(cdr key-bookmark)       #'treemacs-add-bookmark)
              (,(cdr key-edit-ws)        #'treemacs-edit-workspaces)
              (,(cdr key-create-ws)      #'treemacs-create-workspace)
              (,(cdr key-remove-ws)      #'treemacs-remove-workspace)
              (,(cdr key-rename-ws)      #'treemacs-rename-workspace)
              (,(cdr key-switch-ws)      #'treemacs-switch-workspace)
              (,(cdr key-next-ws)        #'treemacs-next-workspace)
              (,(cdr key-fallback-ws)    #'treemacs-set-fallback-workspace)
              (,(cdr key-peek)           #'treemacs-peek-mode)
              (,(cdr key-line-down)      #'treemacs-next-line-other-window)
              (,(cdr key-line-up)        #'treemacs-previous-line-other-window)
              (,(cdr key-page-down)      #'treemacs-next-page-other-window)
              (,(cdr key-page-up)        #'treemacs-previous-previous-other-window)
              (,(cdr key-bulk-actions)   #'treemacs-bulk-file-actions)
              ("<escape>" nil "Exit"))))
        (treemacs--advanced-helpful-hydra/body))
    (treemacs-log-failure "The helpful hydra cannot be summoned without an existing treemacs buffer.")))