summaryrefslogtreecommitdiffstats
path: root/emacs/.emacs.d
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2019-01-13 11:40:01 +0100
committerDavid Robillard <d@drobilla.net>2019-01-13 11:40:01 +0100
commitf58349301167a646059595951f2b721c4e3129d1 (patch)
treeffb0cde691dcf9682bbc10404a24b4b3bdc5bd40 /emacs/.emacs.d
parent6b4b754844bec04990d12e7a3ae5590503eadd40 (diff)
downloaddotfiles-f58349301167a646059595951f2b721c4e3129d1.tar.gz
dotfiles-f58349301167a646059595951f2b721c4e3129d1.tar.bz2
dotfiles-f58349301167a646059595951f2b721c4e3129d1.zip
Shorten projectile mode line
Diffstat (limited to 'emacs/.emacs.d')
-rw-r--r--emacs/.emacs.d/init.el15
1 files changed, 15 insertions, 0 deletions
diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el
index 2edd2ae..1553e67 100644
--- a/emacs/.emacs.d/init.el
+++ b/emacs/.emacs.d/init.el
@@ -210,6 +210,13 @@
'(projectile-completion-system (quote ivy))
'(projectile-enable-caching t)
'(projectile-mode-line nil)
+ '(projectile-mode-line-function
+ (lambda nil
+ (format "%s:%s" projectile-mode-line-prefix
+ (or
+ (projectile-project-name)
+ "-"))))
+ '(projectile-mode-line-prefix "P")
'(projectile-use-git-grep t)
'(quack-pretty-lambda-p t)
'(quack-run-scheme-always-prompts-p nil)
@@ -453,6 +460,14 @@
(add-to-list 'auto-mode-alist '("\\.gyp" . python-mode))
(add-to-list 'auto-mode-alist '("\\.gypi" . python-mode))
+;;; Projectile
+
+(defun my-projectile-mode-line ()
+ "Report project name in the modeline."
+ (format "%s[%s%s]"
+ projectile-mode-line-prefix
+ (or (projectile-project-name) "-")))
+
;;; Launch
(spaceline-spacemacs-theme)