[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 12/38: Fix compatibility for locate-dominating-file
From: |
Leo Liu |
Subject: |
[elpa] 12/38: Fix compatibility for locate-dominating-file |
Date: |
Mon, 24 Mar 2014 09:31:34 +0000 |
leoliu pushed a commit to branch master
in repository elpa.
commit e953417ce0f4d1ceb45da9ef708a8645d0e558d3
Author: Leo Liu <address@hidden>
Date: Fri Mar 7 11:21:20 2014 +0800
Fix compatibility for locate-dominating-file
---
ggtags.el | 15 ++++++++-------
1 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/ggtags.el b/ggtags.el
index 2ecaa29..087a17b 100644
--- a/ggtags.el
+++ b/ggtags.el
@@ -377,17 +377,18 @@ Value is new modtime if updated."
(concat (file-remote-p default-directory)
;; Resolves symbolic links
(ggtags-process-string "global"
"-pr"))))
- ;; 'global -pr' resolves symlinks before checking
- ;; the GTAGS file which could cause issues such as
+ ;; 'global -pr' resolves symlinks before checking the
+ ;; GTAGS file which could cause issues such as
;; https://github.com/leoliu/ggtags/issues/22, so
;; let's help it out.
- (when-let (gtags (locate-dominating-file
- default-directory
- (lambda (dir)
- (file-regular-p (expand-file-name "GTAGS"
dir)))))
+ ;;
+ ;; Note: `locate-dominating-file' doesn't accept
+ ;; function for NAME before 24.3.
+ (let ((gtags (locate-dominating-file default-directory
"GTAGS")))
;; `file-truename' may strip the trailing '/' on
;; remote hosts, see http://debbugs.gnu.org/16851
- (file-name-as-directory (file-truename gtags)))))
+ (and gtags (file-regular-p gtags)
+ (file-name-as-directory (file-truename gtags))))))
(when ggtags-project-root
(if (gethash ggtags-project-root ggtags-projects)
(ggtags-find-project)
- [elpa] 01/38: New command ggtags-show-definition, (continued)
- [elpa] 01/38: New command ggtags-show-definition, Leo Liu, 2014/03/24
- [elpa] 08/38: Call ggtags-show-definition-function in the original buffer, Leo Liu, 2014/03/24
- [elpa] 03/38: Don't display buffer if ggtags-navigation-mode is exited, Leo Liu, 2014/03/24
- [elpa] 07/38: Fix some errors in ggtags-global-output, Leo Liu, 2014/03/24
- [elpa] 04/38: Combine ggtags-global-column and tag name search, Leo Liu, 2014/03/24
- [elpa] 06/38: Fix #34: New variable ggtags-global-always-update, Leo Liu, 2014/03/24
- [elpa] 09/38: Replace ignore-errors with condition-case-unless-debug, Leo Liu, 2014/03/24
- [elpa] 10/38: Automatically use GTAGSCONF file at project root, Leo Liu, 2014/03/24
- [elpa] 05/38: Improve completion support for all tag types, Leo Liu, 2014/03/24
- [elpa] 11/38: Make last change acutally work, Leo Liu, 2014/03/24
- [elpa] 12/38: Fix compatibility for locate-dominating-file,
Leo Liu <=
- [elpa] 14/38: Display project root directory name on mode-line, Leo Liu, 2014/03/24
- [elpa] 22/38: New command ggtags-navigation-isearch-forward, Leo Liu, 2014/03/24
- [elpa] 17/38: Fix ggtags-with-current-project to include GTAGSCONF, Leo Liu, 2014/03/24
- [elpa] 19/38: Use read-only-mode in ggtags-toggle-project-read-only, Leo Liu, 2014/03/24
- [elpa] 18/38: Fix #36: Allow customising path to global's exectuables, Leo Liu, 2014/03/24
- [elpa] 20/38: Teach ggtags-find-tag-dwim to detect #include files, Leo Liu, 2014/03/24
- [elpa] 25/38: Fix ggtags-find-project to check on the GTAGS file, Leo Liu, 2014/03/24
- [elpa] 23/38: Simplify ggtags-save-to-register by always re-do the search, Leo Liu, 2014/03/24
- [elpa] 21/38: Add new command ggtags-save-to-register for #37, Leo Liu, 2014/03/24
- [elpa] 16/38: Fix ggtags-show-definition to run in current project, Leo Liu, 2014/03/24