unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Attila Lendvai <attila@lendvai.name>
To: Maxime Devos <maximedevos@telenet.be>
Cc: guix-devel <guix-devel@gnu.org>
Subject: Re: Guix wiki
Date: Wed, 13 Apr 2022 15:01:17 +0000	[thread overview]
Message-ID: <ylY1pg-zUVXa7W7u6yELAhCsyyssMJB7kjBcSea80F9V_3vcZw7WafNCc3QhLoP11npnPPczrbU7wohBYa7bX0W1Q2Fe9ClNj3BGf2XphMo=@lendvai.name> (raw)
In-Reply-To: <2d93cd88e2ff348cf2c47460c29ff62024c135f9.camel@telenet.be>

> Suggestion: clashing names is not a problem, as long as the final
> package to build actually has an unambigious name. Also, it is not
> necessary to actually give these intermediate packages a variable name,
> maybe do something like
>
> (define-module (gnu packages ...))
> (define-public foo [... a conventional guix package definition ...])
>
> (define-module (my-reproducibility-test)
> #:use-module (gnu packages ...))
>
> (define %version-pins ; <-- TODO: teach "guix import go --pin-versions" to produce this kind of structure?
> ;; package name / version / hash
> '(("go-github-com-operatorfoundation-shapeshifter-transports" "0.1.2" "0f1hzhk3q2fgqdg14zlg3z0s0ib1y9xwj89qnjk95b37zbgqjgsb")
> [...]))
>
> (define pin-input
> (match-lambda
> ((label package . rest)
> (cons* label (pin package) rest))))
>
> (define pin
> (mlambda (package)
> If the package name does not occur in %version-pins --> return package unchanged.
>
> Otherwise, return
> (package
> (inherit package)
> (version the new version)
> (source (origin (inherit (package-source package))
> an appropriately adjusted commit
> the new hash))
> ;; TODO: other versions of dependencies might need extra dependencies
> (inputs (map pin-input package))
> (native-inputs (map pin-input package))
> (propagated-inputs (map pin-input package))))
>
> (define-public my-reproducibility-test-foo
> (package
> (inherit (pin foo))
> (name "foo-as-found-elsewhere")))
>
> Does that suit your purposes?


i'm afraid i can't answer that without further experiments. an immediate concern of mine is that i've seen wild fluctuations in the dependencies of different versions of the same go modules.

this is a great idea, though. thanks, noted!

--
• attila lendvai
• PGP: 963F 5D5F 45C7 DFCD 0A39
--
“When, among a hundred men one man dominates ninety-nine, it is iniquity and despotism. When ten dominate ninety, it is injustice and oligarchy. When fifty-one dominate forty-nine (and this only theoretically, for, in reality, among these fifty-one there are ten or twelve masters), then it is justice and liberty. Could anyone imagine anything more ridiculous and absurd than this reasoning?”
	— Leo Tolstoy (1828–1910), 'The Law of Love and the Law of Violence' (1908)



  reply	other threads:[~2022-04-13 15:01 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-09 21:14 Guix wiki Matt
2022-01-09 21:32 ` Vagrant Cascadian
2022-01-11 13:02   ` Matt
2022-01-11 18:29   ` Jonathan McHugh
2022-04-13 14:46   ` Aurora
2022-01-09 23:55 ` Vincent Legoll
2022-01-11 13:31   ` Matt
2022-01-11 15:17     ` Ricardo Wurmus
2022-01-12  2:52       ` Matt
2022-01-11 15:30     ` Tobias Geerinckx-Rice
2022-01-11 17:15       ` zimoun
2022-01-11 17:27         ` Tobias Geerinckx-Rice
2022-01-11 18:21           ` André A. Gomes
2022-01-11 18:50           ` zimoun
2022-01-12  2:06             ` Tobias Geerinckx-Rice
2022-01-12  8:55               ` zimoun
2022-01-12  9:22                 ` André A. Gomes
2022-01-12  3:51       ` Matt
2022-01-12 15:26         ` Luis Felipe
2022-01-11 16:48     ` Luis Felipe
2022-01-11 21:03     ` Attila Lendvai
2022-01-11 23:18       ` Ricardo Wurmus
2022-01-12  3:28         ` Matt
2022-01-18 14:34           ` Ludovic Courtès
2022-04-11  6:49             ` Attila Lendvai
2022-04-11  8:42               ` Maxime Devos
2022-04-13 15:01                 ` Attila Lendvai [this message]
2022-04-11  8:47               ` Maxime Devos
2022-01-12 11:19         ` Attila Lendvai
2022-01-12 11:52           ` Ricardo Wurmus
2022-01-12 12:00           ` André A. Gomes
2022-01-10  8:29 ` Josua Stingelin
2022-01-12  1:57   ` Matt
2022-01-12  9:19     ` Ricardo Wurmus
2024-01-10  9:55 ` Attila Lendvai
2024-01-17 19:17   ` Maxim Cournoyer

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='ylY1pg-zUVXa7W7u6yELAhCsyyssMJB7kjBcSea80F9V_3vcZw7WafNCc3QhLoP11npnPPczrbU7wohBYa7bX0W1Q2Fe9ClNj3BGf2XphMo=@lendvai.name' \
    --to=attila@lendvai.name \
    --cc=guix-devel@gnu.org \
    --cc=maximedevos@telenet.be \
    /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).