all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: esr@thyrsus.com (Eric S. Raymond)
Cc: emacs-devel@gnu.org
Subject: Re: Git transition checklist
Date: Wed, 08 Jan 2014 20:14:03 +0200	[thread overview]
Message-ID: <837gaafij8.fsf@gnu.org> (raw)
In-Reply-To: <20140108135200.8ECF9380834@snark.thyrsus.com>

> From: esr@thyrsus.com (Eric S. Raymond)
> Date: Wed,  8 Jan 2014 08:52:00 -0500 (EST)
> 
> > 8. There's the emacs-bzr-version whose value gets copied into the bug
> >    reports.  This should be replaced by the suitable git equivalent,
> >    or else the bug reports (of which we have quite a few each day)
> >    will not identify the version correctly.
> 
> Proof of concept (tested):
> 
> (defun emacs-repository-get-version (&optional dir)
>   "Try to return as a string the version-control revision of the Emacs sources.
> Value is nil if the sources do not seem to be under version
> control, or if we could not determine the revision.  Note that
> this reports on the current state of the sources, which may not
> correspond to the running Emacs.
> 
> Optional argument DIR is a directory to use instead of `source-directory'."
>   ;; This is the only function that knows what VCS the Emacs sources are under.
>   (let ((here default-directory))
>     (cd (or dir (setq dir source-directory))) 
>     (message "Waiting for git...")
>     (with-temp-buffer
>       (if (zerop
>            (call-process "git" nil '(t nil) nil "describe" "--tags"))
>          (buffer-string)))
>     (cd here)))

If I run the above git command in the Emacs git repo, I get this:

  $ git describe --tags
  mh-e-8.5-4522-gaa5ae3b

I doubt that we want this.  We want the git sha1 value of the last
commit instead, I think.

> This code is simpler than emacs-bzr-get-version because "git describe" is
> very fast - there's no need to avoid calling it for better performance.

At least here (on MS-Windows), "git describe" is not very fast: with a
warm cache it takes 0.265 sec, with a cold cache it takes several
seconds.

But a command that prints the sha1 value should be much faster (about
30 to 45 msec here).

> The change to integrate this and fix its callers is easy, five minutes'
> work which I will cheerfully do immediately after the repo switchover.
> No need to do it before as it really only becomes crucial to have this
> working for the next point release.

No, I think it needs to be done before the first user checks out the
git repo after the switch, because that signature is important in bug
reports.  We don't want to have builds of Emacs that don't identify
the git commit they are based on, because that makes it harder to
decide whether a bug was already fixed.

So either the above function should be added to Emacs before the
switch, wrapped with some code that would activate it when git starts
to be used, or the repo should be locked for pulls for a few moments
after the switch, until the function is committed.

> Nobody else explicitly suggested any additional preconditions.

I think we have identified another one today: repack the savannah
repository, to avoid both slow initial clone and, what's more, local
repacking that is problematic on slow or low-memory machines.

Thanks.



  parent reply	other threads:[~2014-01-08 18:14 UTC|newest]

Thread overview: 132+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-08 13:52 Git transition checklist Eric S. Raymond
2014-01-08 14:59 ` Stefan Monnier
2014-01-08 16:35   ` Rüdiger Sonderfeld
2014-01-08 17:12     ` Stefan Monnier
2014-01-08 18:08       ` Rüdiger Sonderfeld
2014-01-08 18:21         ` Improved git commit emails [was Re: Git transition checklist] Glenn Morris
2014-01-08 18:31           ` Ted Zlatanov
2014-01-08 18:37             ` Improved git commit emails Glenn Morris
2014-01-08 21:04               ` Ted Zlatanov
2014-01-12  5:44                 ` Bob Proulx
2014-01-13  2:22                   ` Glenn Morris
2014-01-15  2:10                     ` Bob Proulx
2014-01-15  7:35                       ` Glenn Morris
2014-01-20  1:09                         ` Bob Proulx
2014-01-20  2:16                           ` Stephen J. Turnbull
2014-01-20  4:27                             ` Bob Proulx
2014-01-22 19:20                           ` Glenn Morris
2014-01-23 18:42                           ` Rüdiger Sonderfeld
2014-01-28 23:45                             ` Bob Proulx
2014-01-29  0:57                               ` Glenn Morris
2014-01-31  0:41                                 ` Bob Proulx
2014-01-08 16:48   ` Git transition checklist Eric S. Raymond
2014-01-08 17:19     ` Stefan Monnier
2014-01-08 18:43       ` Andreas Schwab
2014-01-08 19:02         ` Glenn Morris
2014-01-08 19:07           ` Eric S. Raymond
2014-01-08 19:17       ` Eric S. Raymond
2014-01-08 17:49     ` Glenn Morris
2014-01-08 18:02   ` Eli Zaretskii
2014-01-08 18:17     ` David Engster
2014-01-08 18:36       ` Eli Zaretskii
2014-01-08 19:07         ` Andreas Schwab
2014-01-08 19:16         ` David Engster
2014-01-08 18:41     ` Andreas Schwab
2014-01-08 18:48       ` Eli Zaretskii
2014-01-08 19:19         ` Andreas Schwab
2014-01-08 15:02 ` Stephen Berman
2014-01-08 16:26   ` Eric S. Raymond
2014-01-08 16:37     ` Git repack on Savannah [was: Re: Git transition checklist] James Cloos
2014-01-12  6:11       ` Bob Proulx
2014-01-12 15:59         ` Eli Zaretskii
2014-01-08 15:33 ` Git transition checklist Bastien
2014-01-08 16:19   ` Eric S. Raymond
2014-01-08 16:20     ` Bastien
2014-01-08 17:48     ` Glenn Morris
2014-01-08 18:15       ` Dani Moncayo
2014-01-08 18:22         ` Glenn Morris
2014-01-08 18:23       ` Andreas Schwab
2014-01-08 18:26         ` Glenn Morris
2014-01-08 18:50           ` Stefan Monnier
2014-01-08 19:00             ` Glenn Morris
2014-01-08 19:41               ` Stefan Monnier
2014-01-08 19:11           ` Andreas Schwab
2014-01-08 19:16             ` Glenn Morris
2014-01-08 19:46               ` Stefan Monnier
2014-01-08 23:07               ` Dani Moncayo
2014-01-12 20:15     ` Bob Proulx
2014-01-13 10:50       ` Bastien
2014-01-08 15:34 ` Bastien
2014-01-08 16:13   ` Eric S. Raymond
2014-01-08 17:47 ` Glenn Morris
2014-01-08 20:02   ` Eric S. Raymond
2014-01-08 20:19     ` Eli Zaretskii
2014-01-08 21:10       ` Andreas Schwab
2014-01-09  0:54         ` James Cloos
2014-01-09  1:23           ` Rüdiger Sonderfeld
2014-01-09  6:38             ` Eli Zaretskii
2014-01-09  0:51       ` James Cloos
2014-01-09  1:36       ` Rüdiger Sonderfeld
2014-01-09  1:48         ` Rüdiger Sonderfeld
2014-01-09  6:41           ` Eli Zaretskii
2014-01-09 11:10             ` Andreas Schwab
2014-01-09 16:17               ` Eli Zaretskii
2014-01-09 16:45                 ` Rüdiger Sonderfeld
2014-01-09 17:44                   ` Eli Zaretskii
2014-01-09 11:53             ` Rüdiger Sonderfeld
2014-01-09  1:53       ` Glenn Morris
2014-01-09  2:13         ` Glenn Morris
2014-01-09 12:14           ` Eric S. Raymond
2014-01-09 14:55             ` Paul Eggert
2014-01-09 15:15               ` Eric S. Raymond
2014-01-09 15:24                 ` Juanma Barranquero
2014-01-09 16:45                   ` Eric S. Raymond
2014-01-09  2:12     ` Glenn Morris
2014-01-09  4:27       ` Stephen J. Turnbull
2014-01-09  7:05         ` Eli Zaretskii
2014-01-09  8:14           ` Stephen J. Turnbull
2014-01-09 11:22             ` Andreas Schwab
2014-01-09 14:30               ` Stephen J. Turnbull
2014-01-09 14:58                 ` David Kastrup
2014-01-09 16:58                 ` Eli Zaretskii
2014-01-09 18:46                   ` Stephen J. Turnbull
2014-01-09 19:03                     ` Eli Zaretskii
2014-01-09 19:40                       ` Óscar Fuentes
2014-01-09 19:47                         ` Eli Zaretskii
2014-01-09 20:12                           ` Óscar Fuentes
2014-01-09 20:17                             ` Glenn Morris
2014-01-09 20:29                             ` Eli Zaretskii
2014-01-09 21:49                               ` Óscar Fuentes
2014-01-10  6:38                                 ` Eli Zaretskii
2014-01-11  9:14                   ` Eli Zaretskii
2014-01-11 20:09                     ` Glenn Morris
2014-01-11 20:32                       ` David Kastrup
2014-01-12 10:30                         ` Jorgen Schaefer
2014-01-13 22:34                           ` Barry Warsaw
2014-01-13 17:06                       ` Glenn Morris
2014-01-13 17:50                         ` David Kastrup
2014-01-14 17:05                           ` Richard Stallman
2014-01-09 15:12         ` Stefan Monnier
2014-01-09 15:33           ` Andreas Schwab
2014-01-08 18:14 ` Eli Zaretskii [this message]
2014-01-08 18:29   ` Glenn Morris
2014-01-08 18:39     ` Eli Zaretskii
2014-01-08 18:46       ` Eli Zaretskii
2014-01-08 20:17         ` David Kastrup
2014-01-08 19:03     ` Andreas Schwab
2014-01-08 18:45   ` Achim Gratz
2014-01-08 18:52     ` Eli Zaretskii
2014-01-08 19:15       ` Achim Gratz
2014-01-08 19:00   ` Andreas Schwab
2014-01-08 20:11   ` Eric S. Raymond
2014-01-08 20:22     ` Eli Zaretskii
2014-01-08 20:28       ` Eric S. Raymond
2014-01-08 21:04         ` Eli Zaretskii
2014-01-08 21:26           ` Eric S. Raymond
2014-01-09  6:25             ` Eli Zaretskii
2014-01-08 21:47       ` David Kastrup
2014-01-08 20:52 ` Eli Zaretskii
2014-01-08 21:07   ` Stefan Monnier
2014-01-08 21:22     ` Eli Zaretskii
  -- strict thread matches above, loose matches on Subject: below --
2014-01-14 17:42 Angelo Graziosi
2014-01-15 12:29 ` Richard Stallman

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=837gaafij8.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=esr@thyrsus.com \
    /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.