summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Leake <stephen_leake@stephe-leake.org>2016-01-27 15:04:33 -0600
committerStephen Leake <stephen_leake@stephe-leake.org>2016-01-29 17:46:18 -0600
commita71560b0e3011c04dc86546b1da51b828cdf040a (patch)
tree04a1369fc846208937c9412f1d4765f28a2a26e1
parent9421b948101689675293a0827ca86321888af83a (diff)
Implement vc-mtn-find-ignore-file, fix some doc strings
* lisp/cedet/cedet-global.el (cedet-gnu-global-root): Improve doc string. * lisp/cedet/ede/locate.el (initialize-instance): Improve doc string. * lisp/vc/vc-git.el (vc-git-find-ignore-file): Fix doc string. * lisp/vc/vc-mtn.el (vc-mtn-find-ignore-file): New function.
-rw-r--r--lisp/cedet/cedet-global.el6
-rw-r--r--lisp/cedet/ede/locate.el2
-rw-r--r--lisp/vc/vc-git.el2
-rw-r--r--lisp/vc/vc-mtn.el4
4 files changed, 9 insertions, 5 deletions
diff --git a/lisp/cedet/cedet-global.el b/lisp/cedet/cedet-global.el
index def023d383..f1cc3c905f 100644
--- a/lisp/cedet/cedet-global.el
+++ b/lisp/cedet/cedet-global.el
@@ -127,9 +127,9 @@ Signal an error if Gnu global not available."
(message "%s" (cedet-gnu-global-root)))
(defun cedet-gnu-global-root (&optional dir)
- "Return the root of any GNU Global scanned project.
-If a default starting DIR is not specified, the current buffer's
-`default-directory' is used."
+ "Return the root of any GNU Global scanned project containing DIR.
+Returns nil if no GNU Global project can be found.
+DIR defaults to `default-directory'."
(let ((default-directory (or dir default-directory)))
(with-current-buffer (cedet-gnu-global-call (list "-pq"))
(goto-char (point-min))
diff --git a/lisp/cedet/ede/locate.el b/lisp/cedet/ede/locate.el
index abbfd60048..38d2388395 100644
--- a/lisp/cedet/ede/locate.el
+++ b/lisp/cedet/ede/locate.el
@@ -231,7 +231,7 @@ variable `cedet-global-command'.")
(let* ((default-directory (oref loc root))
(root (cedet-gnu-global-root)))
(when (not root)
- (error "Cannot use GNU Global in %s"
+ (error "No GNU Global project found for %s"
(oref loc root))))
)
diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el
index 560d303938..1c43e3ec31 100644
--- a/lisp/vc/vc-git.el
+++ b/lisp/vc/vc-git.el
@@ -714,7 +714,7 @@ It is based on `log-edit-mode', and has Git-specific extensions.")
"cat-file" "blob" (concat (if rev rev "HEAD") ":" fullname))))
(defun vc-git-find-ignore-file (file)
- "Return the root directory of the repository of FILE."
+ "Return the git ignore file that controls FILE."
(expand-file-name ".gitignore"
(vc-git-root file)))
diff --git a/lisp/vc/vc-mtn.el b/lisp/vc/vc-mtn.el
index 115a6583bb..0e2e16b44a 100644
--- a/lisp/vc/vc-mtn.el
+++ b/lisp/vc/vc-mtn.el
@@ -102,6 +102,10 @@ switches."
"Return the administrative directory of FILE."
(expand-file-name vc-mtn-admin-dir (vc-mtn-root file)))
+(defun vc-mtn-find-ignore-file (file)
+ "Return the mtn ignore file that controls FILE."
+ (expand-file-name ".mtnignore" (vc-git-root file)))
+
(defun vc-mtn-registered (file)
(let ((root (vc-mtn-root file)))
(when root