]> git.eshelyaron.com Git - emacs.git/commitdiff
Implement vc-mtn-find-ignore-file, fix some doc strings
authorStephen Leake <stephen_leake@stephe-leake.org>
Wed, 27 Jan 2016 21:04:33 +0000 (15:04 -0600)
committerStephen Leake <stephen_leake@stephe-leake.org>
Fri, 29 Jan 2016 23:46:18 +0000 (17:46 -0600)
* 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.

lisp/cedet/cedet-global.el
lisp/cedet/ede/locate.el
lisp/vc/vc-git.el
lisp/vc/vc-mtn.el

index def023d3837ad866b3504251f3e76ae0681b73c3..f1cc3c905f0d1fe03bf698bd80ee4eb15031c92c 100644 (file)
@@ -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))
index abbfd600488d1b0b8c160b98ec06358f4bf252b5..38d2388395191b7d296e067272a271dd2d4477af 100644 (file)
@@ -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))))
   )
 
index 560d303938413a636cd23d6bb8b6e1aa53ffb85b..1c43e3ec31a1e29227ae873e8428f54af3169db8 100644 (file)
@@ -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)))
 
index 115a6583bb6c26988e90a8627d641544cffed98c..0e2e16b44ae3bf0976b53e43c8ff5bf6ac67a68f 100644 (file)
@@ -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