GNU bug report logs - #75981
[PATCH (WIP) v1 0/4] Add 'guix fork'.

Previous Next

Package: guix-patches;

Reported by: 45mg <45mg.writes <at> gmail.com>

Date: Fri, 31 Jan 2025 21:11:02 UTC

Severity: normal

Tags: patch

Full log


View this message in rfc822 format

From: Liliana Marie Prikler <liliana.prikler <at> gmail.com>
To: 45mg <45mg.writes <at> gmail.com>, 75981 <at> debbugs.gnu.org
Cc: Nicolas Graves <ngraves <at> ngraves.fr>, Maxim Cournoyer <maxim.cournoyer <at> gmail.com>, Simon Tournier <zimon.toutoune <at> gmail.com>, Tomas Volf <~@wolfsden.cz>, Ludovic Courtès <ludo <at> gnu.org>, Ricardo Wurmus <rekado <at> elephly.net>, Attila Lendvai <attila <at> lendvai.name>, Simon Streit <simon <at> netpanic.org>
Subject: [bug#75981] [PATCH v2 2/2] scripts: Add `guix git authenticate --branch`.
Date: Sun, 23 Feb 2025 14:56:20 +0100
Am Sonntag, dem 23.02.2025 um 18:50 +0530 schrieb 45mg:
>  (define* (record-configuration repository
> +                               #:optional branch
>                                 #:key commit signer keyring-
> reference)
>    "Record COMMIT, SIGNER, and KEYRING-REFERENCE in the 'config' file
> of
> -REPOSITORY."
> +REPOSITORY, under [guix \"authentication\"].
> +If BRANCH is given, record them under [guix \"authentication-
> BRANCH\"]."
>    (define config
>      (repository-config repository))
> +  (define section
> +    (if branch
> +        (string-append "guix.authentication-" branch)
> +        "guix.authentication"))
>  
>    ;; Guile-Git < 0.7.0 lacks 'set-config-string'.
>    (if (module-defined? (resolve-interface '(git)) 'set-config-
> string)
>        (begin
> -        (set-config-string config "guix.authentication.introduction-
> commit"
> +        (set-config-string config (string-append section
> ".introduction-commit")
>                             commit)
> -        (set-config-string config "guix.authentication.introduction-
> signer"
> +        (set-config-string config (string-append section
> ".introduction-signer")
>                             signer)
> -        (set-config-string config "guix.authentication.keyring"
> +        (set-config-string config (string-append section ".keyring")
>                             keyring-reference)
>          (info (G_ "introduction and keyring recorded \
>  in repository configuration file~%")))
I would use guix.authentication[.BRANCH].KEY for consistency.  Yes, you
can use periods in Git config subsection names as per [1]:
> Subsection names are case sensitive and can contain any characters
> except newline and the null byte. 

Cheers

[1] https://git-scm.com/docs/git-config

This bug report was last modified 109 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.