[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs/lisp vc-git.el
From: |
Michael Albinus |
Subject: |
[Emacs-diffs] emacs/lisp vc-git.el |
Date: |
Tue, 25 Aug 2009 09:01:38 +0000 |
CVSROOT: /sources/emacs
Module name: emacs
Changes by: Michael Albinus <albinus> 09/08/25 09:01:38
Modified files:
lisp : vc-git.el
Log message:
* vc-git.el (vc-git-registered, vc-git-working-revision)
(vc-git-find-revision, vc-git-diff, vc-git-revision-table)
(vc-git--empty-db-p): Let-bind `process-file-side-effects' with nil.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/vc-git.el?cvsroot=emacs&r1=1.86&r2=1.87
Patches:
Index: vc-git.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/vc-git.el,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -b -r1.86 -r1.87
--- vc-git.el 21 Aug 2009 03:37:37 -0000 1.86
+++ vc-git.el 25 Aug 2009 09:01:38 -0000 1.87
@@ -146,7 +146,8 @@
"Check whether FILE is registered with git."
(when (vc-git-root file)
(with-temp-buffer
- (let* ((dir (file-name-directory file))
+ (let* (process-file-side-effects
+ (dir (file-name-directory file))
(name (file-relative-name file dir))
(str (ignore-errors
(when dir (cd dir))
@@ -183,7 +184,8 @@
(defun vc-git-working-revision (file)
"Git-specific version of `vc-working-revision'."
- (let ((str (with-output-to-string
+ (let* (process-file-side-effects
+ (str (with-output-to-string
(with-current-buffer standard-output
(vc-git--out-ok "symbolic-ref" "HEAD")))))
(if (string-match "^\\(refs/heads/\\)?\\(.+\\)$" str)
@@ -439,7 +441,8 @@
(if vc-git-add-signoff "-s") "-m" comment "--only" "--")))
(defun vc-git-find-revision (file rev buffer)
- (let ((coding-system-for-read 'binary)
+ (let* (process-file-side-effects
+ (coding-system-for-read 'binary)
(coding-system-for-write 'binary)
(fullname (substring
(vc-git--run-command-string
@@ -528,15 +531,17 @@
(defun vc-git-diff (files &optional rev1 rev2 buffer)
"Get a difference report using Git between two revisions of FILES."
+ (let (process-file-side-effects)
(apply #'vc-git-command (or buffer "*vc-diff*") 1 files
(if (and rev1 rev2) "diff-tree" "diff-index")
"--exit-code"
(append (vc-switches 'git 'diff)
- (list "-p" (or rev1 "HEAD") rev2 "--"))))
+ (list "-p" (or rev1 "HEAD") rev2 "--")))))
(defun vc-git-revision-table (files)
;; What about `files'?!? --Stef
- (let ((table (list "HEAD")))
+ (let (process-file-side-effects
+ (table (list "HEAD")))
(with-temp-buffer
(vc-git-command t nil nil "for-each-ref" "--format=%(refname)")
(goto-char (point-min))
@@ -736,7 +741,8 @@
(defun vc-git--empty-db-p ()
"Check if the git db is empty (no commit done yet)."
- (not (eq 0 (vc-git--call nil "rev-parse" "--verify" "HEAD"))))
+ (let (process-file-side-effects)
+ (not (eq 0 (vc-git--call nil "rev-parse" "--verify" "HEAD")))))
(defun vc-git--call (buffer command &rest args)
;; We don't need to care the arguments. If there is a file name, it
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] emacs/lisp vc-git.el,
Michael Albinus <=