From 8ba3ffad71c8854c3a0bfe4d9bda6ab221da439f Mon Sep 17 00:00:00 2001 From: mattkae Date: Fri, 21 Oct 2022 07:41:42 -0400 Subject: Refreshing the window and navigating back to current buffer after file ops --- lisp/general.el | 15 ++++++++++----- lisp/lisp.el | 4 ++++ 2 files changed, 14 insertions(+), 5 deletions(-) (limited to 'lisp') diff --git a/lisp/general.el b/lisp/general.el index 2428518..4bbf6f0 100644 --- a/lisp/general.el +++ b/lisp/general.el @@ -146,7 +146,8 @@ (interactive) (call-interactively #'make-empty-file) (neotree-show) - (neotree-refresh)) + (neotree-refresh) + (other-window -1)) (bind-key* (kbd "M-n") 'my-create-file) @@ -155,7 +156,8 @@ (interactive) (call-interactively #'make-directory) (neotree-show) - (neotree-refresh)) + (neotree-refresh) + (other-window -1)) (bind-key* (kbd "M-N") 'my-create-directory) (defun my-delete-file () @@ -163,7 +165,8 @@ (interactive) (call-interactively #'delete-file) (neotree-show) - (neotree-refresh)) + (neotree-refresh) + (other-window -1)) (bind-key* (kbd "M-d") 'my-delete-file) (defun my-delete-directory () @@ -171,7 +174,8 @@ (interactive) (call-interactively #'delete-directory) (neotree-show) - (neotree-refresh)) + (neotree-refresh) + (other-window -1)) (bind-key* (kbd "M-D") 'my-delete-directory) (defun my-rename-file () @@ -179,7 +183,8 @@ (interactive) (call-interactively #'rename-file) (neotree-show) - (neotree-refresh)) + (neotree-refresh) + (other-window -1)) (bind-key* (kbd "M-r") 'my-rename-file) ;; Company mode for code completion diff --git a/lisp/lisp.el b/lisp/lisp.el index c313d53..01199ca 100644 --- a/lisp/lisp.el +++ b/lisp/lisp.el @@ -7,6 +7,10 @@ (company-mode t) ) +(require 'projectile) +(with-eval-after-load 'projectile + (add-to-list 'projectile-globally-ignored-directories "elpa")) + (add-hook 'emacs-lisp-mode-hook 'setup-lisp) (provide 'lisp) ;;; lisp.el ends here -- cgit v1.2.1