* [patch] vc-git-dired-state-info buglet
@ 2007-11-23 12:09 Thien-Thi Nguyen
2007-11-27 21:55 ` Alexandre Julliard
0 siblings, 1 reply; 3+ messages in thread
From: Thien-Thi Nguyen @ 2007-11-23 12:09 UTC (permalink / raw)
To: emacs-devel
i think `vc-git-dired-state-info' should call `vc-git-state'
instead of `vc-state'. here is a recipe: create dir `test',
put it under git version control system, add and commit some
files, then modify a subset of the files. then do:
C-x v d test RET ; => empty because no files "locked"
v t ; => toggle terse mode
before the patch, no files are shown w/ "(modified)" status.
after the patch, some are shown, as i expected.
i wonder if my expectation is incorrect. comments?
thi
________________________________________________________
*** vc-git.el 20 Oct 2007 01:28:35 -0000 1.25
--- vc-git.el 23 Nov 2007 12:02:57 -0000
***************
*** 205,211 ****
(defun vc-git-dired-state-info (file)
"Git-specific version of `vc-dired-state-info'."
! (let ((git-state (vc-state file)))
(if (eq git-state 'edited)
"(modified)"
;; fall back to the default VC representation
--- 205,211 ----
(defun vc-git-dired-state-info (file)
"Git-specific version of `vc-dired-state-info'."
! (let ((git-state (vc-git-state file)))
(if (eq git-state 'edited)
"(modified)"
;; fall back to the default VC representation
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [patch] vc-git-dired-state-info buglet
2007-11-23 12:09 [patch] vc-git-dired-state-info buglet Thien-Thi Nguyen
@ 2007-11-27 21:55 ` Alexandre Julliard
2007-11-29 7:22 ` Dan Nicolaescu
0 siblings, 1 reply; 3+ messages in thread
From: Alexandre Julliard @ 2007-11-27 21:55 UTC (permalink / raw)
To: Thien-Thi Nguyen; +Cc: emacs-devel
Thien-Thi Nguyen <ttn@gnuvola.org> writes:
> i think `vc-git-dired-state-info' should call `vc-git-state'
> instead of `vc-state'. here is a recipe: create dir `test',
> put it under git version control system, add and commit some
> files, then modify a subset of the files. then do:
>
> C-x v d test RET ; => empty because no files "locked"
> v t ; => toggle terse mode
>
> before the patch, no files are shown w/ "(modified)" status.
> after the patch, some are shown, as i expected.
>
> i wonder if my expectation is incorrect. comments?
That's not the real problem, the other backends also use vc-state here
and it works fine. The real problem is that vc-git-dir-state is
broken. Something like this should help:
Index: lisp/vc-git.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/vc-git.el,v
retrieving revision 1.29
diff -u -p -r1.29 vc-git.el
--- lisp/vc-git.el 25 Nov 2007 00:41:49 -0000 1.29
+++ lisp/vc-git.el 27 Nov 2007 21:54:06 -0000
@@ -152,7 +152,7 @@
(defun vc-git-dir-state (dir)
(with-temp-buffer
- (vc-git-command (current-buffer) nil nil "ls-files" "-t")
+ (vc-git-command (current-buffer) nil nil "ls-files" "-t" "-c" "-m" "-o")
(goto-char (point-min))
(let ((status-char nil)
(file nil))
--
Alexandre Julliard
julliard@winehq.org
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [patch] vc-git-dired-state-info buglet
2007-11-27 21:55 ` Alexandre Julliard
@ 2007-11-29 7:22 ` Dan Nicolaescu
0 siblings, 0 replies; 3+ messages in thread
From: Dan Nicolaescu @ 2007-11-29 7:22 UTC (permalink / raw)
To: Alexandre Julliard; +Cc: Thien-Thi Nguyen, emacs-devel
Alexandre Julliard <julliard@winehq.org> writes:
> Thien-Thi Nguyen <ttn@gnuvola.org> writes:
>
> > i think `vc-git-dired-state-info' should call `vc-git-state'
> > instead of `vc-state'. here is a recipe: create dir `test',
> > put it under git version control system, add and commit some
> > files, then modify a subset of the files. then do:
> >
> > C-x v d test RET ; => empty because no files "locked"
> > v t ; => toggle terse mode
> >
> > before the patch, no files are shown w/ "(modified)" status.
> > after the patch, some are shown, as i expected.
> >
> > i wonder if my expectation is incorrect. comments?
>
> That's not the real problem, the other backends also use vc-state here
> and it works fine. The real problem is that vc-git-dir-state is
> broken. Something like this should help:
Thanks, I've checked in this patch.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-11-29 7:22 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-23 12:09 [patch] vc-git-dired-state-info buglet Thien-Thi Nguyen
2007-11-27 21:55 ` Alexandre Julliard
2007-11-29 7:22 ` Dan Nicolaescu
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).