unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Liliana Marie Prikler <liliana.prikler@gmail.com>
To: Maxime Devos <maximedevos@telenet.be>, Guix-devel <guix-devel@gnu.org>
Cc: blake@reproduciblemedia.com,
	"Julien Lepiller" <julien@lepiller.eu>,
	"Ludovic Courtès" <ludo@gnu.org>,
	"Philip McGrath" <philip@philipmcgrath.com>
Subject: Re: [PATCH] doc: Update contribution guidelines on patches, etc.
Date: Tue, 09 Aug 2022 19:05:15 +0200	[thread overview]
Message-ID: <94958dc21ac67cda21530d512ee10b32b76d5d28.camel@gmail.com> (raw)
In-Reply-To: <9e87d335-ed11-1bd9-fe72-9ba23ae4af63@telenet.be>

Am Dienstag, dem 09.08.2022 um 18:45 +0200 schrieb Maxime Devos:
> On 06-08-2022 08:55, Liliana Marie Prikler wrote:
> 
> > +If your package has a bug that takes multiple lines to fix,
> I don't think this is true for replacing all instances of "foo" by 
> "/gnu/store/.../bin/foo" in a file.
Should it?

> >   or a fix
> > +has already been accepted upstream, patches are the preferred way
> > of
> > +eliminating said bug
> > +Refer to the @code{origin} record documentation
> > +(particularly the fields @code{snippet} and @code{modules}), for
> > more
> > +information (@pxref{origin Reference}).
> > +
> 
> The "Refer to the ... documentation for more information" occurred in
> the old version of (guix)Snippets versus Phases. However, back then,
> I did not find more information on how to decide between snippets,
> patches and phases, and neither do I now.
> 
> Maybe:
> 
> +Refer to the @code{origin} record documentation
> +(@pxref{origin Reference}) (particularly the fields @code{snippet}
> and @code{modules})
> +for more information on how to use snippets
> 
> , to avoid a reader's assumption that that section contains
> information on deciding between snippets, phases and patches.
Yeah, this was meant for "how to use".

> > + Furthermore, as with patches, modifying the snippets causes two
> > derivations to be built.
> 
> This is true, but I don't think reviewers and package authors have to
> worry about that.
It does make a difference to the author when debugging their package. 
Starting with a phase and then moving it to a snippet can save good
time.

> > Such changes include, but are not limited to fixes of the
> > +build script(s) or embeddings of store paths (e.g. replacement of
> > +@file{/bin/sh} with @code{(search-input-file inputs "bin/sh")}).
> Include what? I think you need to close the subsentence here:
> 
> > +Such changes include, but are not limited to, fixes of the build
> > +script(s) or embeddings of store paths (e.g. [...])
> > 
> 
> [...]
Is that how to English comma?  Sorry, I'm not a native speaker so I get
somewhat weirded out by the when to skip/not to skip rules.

> > +Build phases are limited in that they do not modify the source
> > +derivation.  Thus, they are inadequate for changes that are to be
> > +reflected in the source code.  On the other hand, they only cause
> > a
> > +single rebuild and are thus slightly easier to debug than phases
> > and
> > +snippets.
> Derivations are a rather low-level concept, could they be avoided in
> the origin and phases documentation?
I don't quite see how.  You could s/source derivation/the result of
@code{guix build -S}/, but I don't think that's much better.

> > +Build phases are limited in that they do not modify the source
> > +derivation.  Thus, they are inadequate for changes that are to be
> > +reflected in the source code.  On the other hand, they only cause
> > a
> > +single rebuild and are thus slightly easier to debug than phases
> > and
> > +snippets.
> See Andreas' comment on phase->snippet.
> 
> Also, do I understand correctly that the argument here is that
> 'single rebuild -> less compilation time -> easier to debug'?
Easier to debug for the package author currently fiddling with the
phase/snippet.  Not really a statement in any direction otherwise.

Cheers



  reply	other threads:[~2022-08-09 17:13 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-25  3:17 A proposal of a consistent set of clear rules and guidelines involving snippets, phases and patches Maxime Devos
2022-07-25  5:21 ` Julien Lepiller
2022-07-25 11:18   ` Maxime Devos
2022-07-25 11:37     ` Julien Lepiller
2022-08-04  8:51 ` Ludovic Courtès
2022-08-05  3:23 ` Philip McGrath
2022-08-05  8:13   ` Maxime Devos
2022-08-05  3:38 ` Philip McGrath
2022-08-05  8:09   ` Maxime Devos
2022-08-05 10:18 ` Maxime Devos
2022-08-05 13:59 ` v2: " Maxime Devos
2022-08-06  6:55   ` [PATCH] doc: Update contribution guidelines on patches, etc Liliana Marie Prikler
2022-08-06  6:55     ` [PATCH v2] " Liliana Marie Prikler
2022-09-02 13:12       ` Ludovic Courtès
2022-09-02 18:05         ` Maxime Devos
2022-09-05  9:47           ` Ludovic Courtès
2022-09-05 13:12             ` Maxime Devos
2022-09-05 16:05               ` Maxime Devos
2022-08-09 16:45     ` [PATCH] " Maxime Devos
2022-08-09 17:05       ` Liliana Marie Prikler [this message]
2022-08-09 18:19         ` Maxime Devos
2022-08-09 19:08           ` Liliana Marie Prikler
2022-08-09 20:30             ` Maxime Devos
2022-08-10  4:25               ` Liliana Marie Prikler
2022-08-09 20:40             ` Maxime Devos
2022-08-08 21:51   ` v2: A proposal of a consistent set of clear rules and guidelines involving snippets, phases and patches Andreas Enge
2022-08-09 15:06     ` Maxime Devos
2022-08-09 17:10       ` Andreas Enge
2022-09-05 13:03     ` Maxime Devos
2022-09-07 12:17       ` Andreas Enge
2022-09-07 18:08         ` Maxime Devos
2022-08-09 18:58   ` david larsson
2022-08-09 20:53     ` Maxime Devos
2022-08-10 11:23       ` david larsson
2022-08-05 16:59 ` blake
2022-08-09 16:30   ` Maxime Devos
2022-09-05 14:06     ` Maxime Devos
2022-08-10  6:10   ` blake
2022-08-10  9:06     ` Maxime Devos
2022-08-10 10:33     ` blake
2022-08-10 10:44       ` Maxime Devos

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

  List information: https://guix.gnu.org/

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

  git send-email \
    --in-reply-to=94958dc21ac67cda21530d512ee10b32b76d5d28.camel@gmail.com \
    --to=liliana.prikler@gmail.com \
    --cc=blake@reproduciblemedia.com \
    --cc=guix-devel@gnu.org \
    --cc=julien@lepiller.eu \
    --cc=ludo@gnu.org \
    --cc=maximedevos@telenet.be \
    --cc=philip@philipmcgrath.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 public inbox

	https://git.savannah.gnu.org/cgit/guix.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).