From: Dan Nicolaescu Date: Wed, 14 Oct 2009 06:28:00 +0000 (+0000) Subject: (vc-git-dir-extra-headers): Set the branch name X-Git-Tag: emacs-pretest-23.1.90~810 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=52964e54742df3ecd7ff5a4652274816b2abf612;p=emacs.git (vc-git-dir-extra-headers): Set the branch name correctly in the detached head case. (vc-git-print-log): Remove unused binding. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b10a077b810..70c22dda440 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2009-10-14 Dan Nicolaescu + * vc-git.el (vc-git-dir-extra-headers): Set the branch name + correctly in the detached head case. + (vc-git-print-log): Remove unused binding. + * vc.el (vc-responsible-backend): When a directory is passed for for registration create a VC repository if no backend is responsible for the directory argument. diff --git a/lisp/vc-git.el b/lisp/vc-git.el index fe7b95cb43a..6a757e32dad 100644 --- a/lisp/vc-git.el +++ b/lisp/vc-git.el @@ -421,7 +421,7 @@ If nil, use the value of `vc-diff-switches'. If t, use no switches." (vc-git--out-ok "config" (concat "remote." remote ".url")))))) (when (string-match "\\([^\n]+\\)" remote-url) (setq remote-url (match-string 1 remote-url)))) - "not (detached HEAD)") + (setq branch "not (detached HEAD)")) ;; FIXME: maybe use a different face when nothing is stashed. (concat (propertize "Branch : " 'face 'font-lock-type-face) @@ -503,10 +503,7 @@ If nil, use the value of `vc-diff-switches'. If t, use no switches." (defun vc-git-print-log (files &optional buffer shortlog) "Get change log associated with FILES." - (let ((coding-system-for-read git-commits-coding-system) - ;; Support both the old print-log interface that passes a - ;; single file, and the new one that passes a file list. - (flist (if (listp files) files (list files)))) + (let ((coding-system-for-read git-commits-coding-system)) ;; `vc-do-command' creates the buffer, but we need it before running ;; the command. (vc-setup-buffer buffer)