Skip to content

Instantly share code, notes, and snippets.

@mads-hartmann
Created March 17, 2017 09:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mads-hartmann/cc66460aa93906959dab7412d34d5c95 to your computer and use it in GitHub Desktop.
Save mads-hartmann/cc66460aa93906959dab7412d34d5c95 to your computer and use it in GitHub Desktop.
A modification to mhj/show-project-explorer as requested by Benjamín Buccianti
(defun mhj/show-project-explorer ()
"Project dired buffer on the side of the frame.
Shows the projectile root folder using dired on the left side of
the frame and makes it a dedicated window for that buffer."
(let ((buffer (dired-noselect (projectile-project-root))))
(progn
(display-buffer-in-side-window buffer '((side . left) (window-width . 0.2)))
(set-window-dedicated-p (get-buffer-window buffer) t)
(select-window (get-buffer-window buffer)))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment