diff options
Diffstat (limited to 'emacs.d/wpc/functions.el')
-rw-r--r-- | emacs.d/wpc/functions.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/emacs.d/wpc/functions.el b/emacs.d/wpc/functions.el index f2514a1bed85..29886b30413d 100644 --- a/emacs.d/wpc/functions.el +++ b/emacs.d/wpc/functions.el @@ -223,5 +223,11 @@ (term-char-mode) (term-line-mode))) +(defun buffer-dirname () + "Return the directory name of the current buffer as a string." + (->> buffer-file-name + f-dirname + f-filename)) + (provide 'functions) ;;; functions.el ends here |