From: "Ludovic Courtès" <ludo@gnu.org>
To: jgart <jgart@dismail.de>
Cc: Julien Lepiller <julien@lepiller.eu>, 50274@debbugs.gnu.org
Subject: [bug#50274] [PATCH] guix: git: Adds feature to download git repository to the store.
Date: Fri, 24 Sep 2021 14:25:49 +0200 [thread overview]
Message-ID: <87y27mma7m.fsf@gnu.org> (raw)
In-Reply-To: <20210830163918.19419-1-jgart@dismail.de> (jgart@dismail.de's message of "Mon, 30 Aug 2021 12:39:19 -0400")
Hi Julien & jgart,
jgart <jgart@dismail.de> skribis:
> From: Julien Lepiller <julien@lepiller.eu>
>
> * guix/git.scm (download-git-to-store): Download Git repository from
> URL at COMMIT to STORE, either under NAME or URL's basename if omitted.
> Write progress reports to LOG. RECURSIVE? has the same effect as the
> same-named parameter of 'git-fetch'.
>
> * guix/scripts/download.scm (download-git-to-store*): Adds cli option.
> Examples:
> guix download --git-commit=v0.1.1 github.com/anaseto/gruid-tcell
> guix download -c v0.1.1 https://github.com/anaseto/gruid-tcell
Very useful!
> +(define* (download-git-to-store store url commit
> + #:optional (name (basename url))
> + #:key (log (current-error-port)) recursive?)
> + "Download Git repository from URL at COMMIT to STORE, either under NAME or
> +URL's basename if omitted. Write progress reports to LOG. RECURSIVE? has the
> +same effect as the same-named parameter of 'git-fetch'."
Can we use ‘latest-repository-commit’ instead? The difference is that
it’ll populate ~/.cache/guix/checkouts, but I think that’s fine.
OTOH, if we want to make it easier to support other VCSes, we can choose
to not use (guix git) at all and instead use ‘git-fetch’ in (guix
git-download), ‘hg-fetch’ in (guix hg-download), etc. This code would
go to (guix scripts hash).
WDYT?
[...]
> + (option '(#\c "git-commit") #t #f
> + (lambda (opt name arg result)
> + (alist-cons 'commit arg result)))
For consistency with package transformation options, I’d call it
‘--commit’. This option would still apply if/when other VCSes are
supported.
This would also need an update of the manual.
Thanks,
Ludo’.
next prev parent reply other threads:[~2021-09-24 12:27 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-30 16:39 [bug#50274] [PATCH] guix: git: Adds feature to download git repository to the store jgart via Guix-patches via
2021-08-31 18:50 ` Sarah Morgensen
2021-08-31 22:28 ` Maxime Devos
2021-08-31 19:08 ` Sarah Morgensen
2021-08-31 19:30 ` jgart via Guix-patches via
2021-08-31 20:06 ` jgart via Guix-patches via
2021-09-03 1:37 ` Sarah Morgensen
2021-09-24 12:25 ` Ludovic Courtès [this message]
2021-09-26 6:24 ` Sarah Morgensen
2021-09-30 20:03 ` Ludovic Courtès
2023-08-01 1:21 ` TakeV via Guix-patches via
2023-08-18 17:55 ` Simon Tournier
2023-08-18 21:02 ` TakeV via Guix-patches via
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=87y27mma7m.fsf@gnu.org \
--to=ludo@gnu.org \
--cc=50274@debbugs.gnu.org \
--cc=jgart@dismail.de \
--cc=julien@lepiller.eu \
/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/guix.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.