all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Dan Nicolaescu <dann@ics.uci.edu>
Cc: mail.vjrao@gmail.com, emacs-devel@gnu.org,
	Nick Roberts <nickrob@snap.net.nz>, "rms@gnu.org" <rms@gnu.org>
Subject: Re: TODO
Date: Tue, 26 Feb 2008 13:26:34 -0500	[thread overview]
Message-ID: <jwv1w6zd1em.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <200802261813.m1QIDEku015891@sallyv1.ics.uci.edu> (Dan Nicolaescu's message of "Tue, 26 Feb 2008 10:13:13 -0800")

>> Please let me know if anyone is already working on one of these tasks.
>> 
>> ** make emacsclient accept -nw as a synonym to -t.
>> 
>> ** Replace some uses of the preprocessor code in Makefile.in with the
>> equivalent autoconf.
>> 
>> ** Make "emacs --daemon" start emacs without showing any frame.
>> Use emacsclient later to open frames.

> AFAIK nobody has publicly announced that is working on any of these.

> Do you have a copyright assignment on file?  If not, it would make sense
> to get started on that as soon as possible, so that it is ready by the
> time you finish writing the code.


>> ** Make vc-checkin avoid reverting the buffer if has not changed after
>> the checkin. Comparing (md5 BUFFER) to (md5 FILE) should be enough.

> I have a patch for this one.

> But it needs a few more eyes on it from people that know the code
> involved very well to make sure it is correct and the right thing to do.
> The patch itself is not too complicated.

BTW, I'd like someone to clarify the goal.  I.e. what is it trying
to fix.  It seems that if the file hasn't been changed, the current code
should at the very least end up not modifying the buffer (since
insert-file-contents already compares the bytes to find the unchanged
prefix and suffix).  So what is the difference in this case between
calling revert-buffer and not calling it?

Also I expect that if the file hasn't changed, it will often have kept
its modification time as well, so in which circumstances would the
modtime check fail but the md5 check succeed?


        Stefan


> --- vc.el       10 Oct 2007 10:34:53 -0700      1.464
> +++ vc.el       11 Oct 2007 12:18:02 -0700      
> @@ -1328,7 +1327,19 @@
>      (save-excursion
>        ;; t means don't call normal-mode;
>        ;; that's to preserve various minor modes.
> -      (revert-buffer arg no-confirm t))
> +      (if (string=
> +          (with-temp-buffer
> +            ;; Insert the file on disk in a temporary buffer and compute the md5 there.
> +            (let ((coding-system-for-read 'binary))
> +              (insert-file-contents file)
> +              (md5 (current-buffer))))
> +          (md5 (current-buffer)))  ;; md5 for the current buffer
> +         (let ((writable (file-writable-p (buffer-file-name)))) ;; Try to set the read-only state.
> +           (unless (eq buffer-read-only writable)
> +             (setq buffer-read-only writable))
> +           (message "not reverting"))
> +       (message "reverting :-(")
> +       (revert-buffer arg no-confirm t)))
>      (vc-restore-buffer-context context)))
 
>  (defun vc-buffer-sync (&optional not-urgent)





  reply	other threads:[~2008-02-26 18:26 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-23 17:26 Looking for a new Emacs maintainer or team Vijay Rao
2008-02-24  0:54 ` Richard Stallman
2008-02-24 16:12   ` Vijay Rao
2008-02-24 23:04     ` Richard Stallman
2008-02-25  3:59       ` Vijay Rao
2008-02-25  4:45         ` TODO [was Re: Looking for a new Emacs maintainer or team] Nick Roberts
2008-02-26 15:33           ` V.Rao
2008-02-26 18:13             ` Dan Nicolaescu
2008-02-26 18:26               ` Stefan Monnier [this message]
2008-02-26 18:48                 ` TODO Dan Nicolaescu
2008-02-26 18:54                   ` TODO Stefan Monnier
2008-02-26 19:03                     ` TODO Dan Nicolaescu
2008-02-26 23:08                   ` TODO Miles Bader
2008-02-26 23:23                     ` TODO Dan Nicolaescu
2008-02-27  0:08                       ` TODO Miles Bader
2008-02-27  1:17                         ` TODO Dan Nicolaescu
2008-02-27  2:56                           ` TODO Miles Bader
2008-02-27 16:07                   ` TODO Richard Stallman
2008-02-27 20:45                     ` TODO Stefan Monnier
2008-02-28 16:41                       ` TODO Richard Stallman
2008-02-28 17:09               ` TODO [was Re: Looking for a new Emacs maintainer or team] V.Rao
2008-02-29  1:39                 ` Richard Stallman
2008-02-28  2:00             ` Xavier Maillard
2008-02-28 16:20               ` TODO Michael Albinus
2008-02-28 17:08                 ` TODO Dan Nicolaescu
2008-02-28 17:35                 ` TODO Stefan Monnier
2008-02-28 20:39                   ` TODO Michael Albinus
2008-02-28 23:23                     ` TODO Evans Winner
2008-02-29  4:52                     ` TODO Dan Nicolaescu
2008-02-29  7:58                       ` TODO Michael Albinus
2008-03-01  1:00                         ` TODO Xavier Maillard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwv1w6zd1em.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=dann@ics.uci.edu \
    --cc=emacs-devel@gnu.org \
    --cc=mail.vjrao@gmail.com \
    --cc=nickrob@snap.net.nz \
    --cc=rms@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.