aboutsummaryrefslogtreecommitdiff
path: root/projectile.el
diff options
context:
space:
mode:
Diffstat (limited to 'projectile.el')
-rw-r--r--projectile.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/projectile.el b/projectile.el
index eed377a..7f0c581 100644
--- a/projectile.el
+++ b/projectile.el
@@ -1325,7 +1325,10 @@ Return the first (topmost) matched directory or nil if not found."
(projectile-locate-dominating-file
dir
(lambda (dir)
- (cl-find-if (lambda (f) (projectile-file-exists-p (projectile-expand-file-name-wildcard f dir)))
+ (cl-find-if (lambda (f)
+ (let ((expanded (projectile-expand-file-name-wildcard f dir)))
+ (and (projectile-file-exists-p expanded)
+ (not (file-directory-p expanded)))))
(or list projectile-project-root-files)))))
(defun projectile-root-marked (dir)