summaryrefslogtreecommitdiff
path: root/init/km-projectile.el
blob: a5f3b3e95671964be880a31e3de1ca7fa5185683 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
(projectile-global-mode)

(setq projectile-switch-project-action 'km/projectile-magit-status)

(defun km/projectile-magit-status ()
  (magit-status (projectile-project-root)))

(defun km/projectile-switch-project-to-file ()
  "I have set `projectile-switch-project-action' to
  `km/projectile-magit-status'. This function gives access to the
  of default `projectile-find-file'"
  (interactive)
  (let ((projectile-switch-project-action 'projectile-find-file))
    (projectile-switch-project)))

(global-set-key (kbd "C-c p j")  'km/projectile-switch-project-to-file)