From: Stefan Monnier Date: Fri, 1 Jul 2011 17:45:31 +0000 (-0400) Subject: * lisp/vc/vc-bzr.el (vc-bzr-revision-keywords): Update. X-Git-Tag: emacs-pretest-24.0.90~104^2~152^2~264 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=eb604e34e566f3f8b03d2f77f178d75e5e4743c1;p=emacs.git * lisp/vc/vc-bzr.el (vc-bzr-revision-keywords): Update. (vc-bzr-revision-completion-table): Add support for annotate and date. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2bb0bad7282..df8aa7e8845 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-01 Stefan Monnier + * vc/vc-bzr.el (vc-bzr-revision-keywords): Update. + (vc-bzr-revision-completion-table): Add support for annotate and date. + * emacs-lisp/derived.el (define-derived-mode): Make abbrev-table inherit from parent. @@ -27,7 +30,7 @@ (cfengine3-class-selector-regex cfengine3-category-regex) (cfengine3-vartypes cfengine3-font-lock-keywords) (cfengine3-beginning-of-defun, cfengine3-end-of-defun) - (cfengine3-indent-line): Added from cfengine3.el. + (cfengine3-indent-line): Add from cfengine3.el. 2011-07-01 Michael Albinus diff --git a/lisp/vc/vc-bzr.el b/lisp/vc/vc-bzr.el index fa59b7ef19c..0fdb2230af8 100644 --- a/lisp/vc/vc-bzr.el +++ b/lisp/vc/vc-bzr.el @@ -1172,8 +1172,9 @@ stream. Standard error output is discarded." (eval-and-compile (defconst vc-bzr-revision-keywords - '("revno" "revid" "last" "before" - "tag" "date" "ancestor" "branch" "submit"))) + ;; bzr help revisionspec | sed -ne 's/^\([a-z]*\):$/"\1"/p' | sort -u + '("ancestor" "annotate" "before" "branch" "date" "last" "mainline" "revid" + "revno" "submit" "svn" "tag"))) (defun vc-bzr-revision-completion-table (files) (lexical-let ((files files)) @@ -1211,6 +1212,19 @@ stream. Standard error output is discarded." (push (match-string-no-properties 1) table))) (completion-table-with-context prefix table tag pred action))) + ((string-match "\\`annotate:" string) + (completion-table-with-context + (substring string 0 (match-end 0)) + (apply-partially #'completion-table-with-terminator '(":" . "\\`a\\`") + #'completion-file-name-table) + (substring string (match-end 0)) pred action)) + + ((string-match "\\`date:" string) + (completion-table-with-context + (substring string 0 (match-end 0)) + '("yesterday" "today" "tomorrow") + (substring string (match-end 0)) pred action)) + ((string-match "\\`\\([a-z]+\\):" string) ;; no actual completion for the remaining keywords. (completion-table-with-context (substring string 0 (match-end 0))