From: Andrew Tropin <andrew@trop.in>
To: zimoun <zimon.toutoune@gmail.com>
Cc: 50296@debbugs.gnu.org
Subject: [bug#50296] [PATCH 1/2] scripts: Add 'guix home'.
Date: Wed, 01 Sep 2021 08:20:17 +0300 [thread overview]
Message-ID: <87lf4gzxbi.fsf@trop.in> (raw)
In-Reply-To: <CAJ3okZ2X5QAJBRZDgtqOFaBbMWJDRpn-oHBeKMTwwL1LdkahQw@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1953 bytes --]
On 2021-08-31 15:09, zimoun wrote:
> Hi,
>
> On Tue, 31 Aug 2021 at 14:12, Andrew Tropin <andrew@trop.in> wrote:
>> On 2021-08-31 12:53, zimoun wrote:
>> > On Tue, 31 Aug 2021 at 12:40, Andrew Tropin <andrew@trop.in> wrote:
>> >
>> >> +(define-command (guix-home . args)
>> >> + (synopsis "build and deploy home environments")
>> >> +
>> >> + (define (parse-sub-command arg result)
>> >> + ;; Parse sub-command ARG and augment RESULT accordingly.
>> >> + (if (assoc-ref result 'action)
>> >> + (alist-cons 'argument arg result)
>> >> + (let ((action (string->symbol arg)))
>> >> + (case action
>> >> + ((build
>> >> + reconfigure
>> >> + extension-graph shepherd-graph
>> >> + list-generations describe
>> >> + delete-generations roll-back
>> >> + switch-generation search
>> >> + import)
>> >> + (alist-cons 'action action result))
>> >> + (else (leave (G_ "~a: unknown action~%") action))))))
>> >
>> > For parsing the actions, I would define elsewhere the list. Then if the
>> > action is unknown, you could use ’string-closest’ and so return an hint
>> > if there is a typo.
>
> [...]
>
>> Sounds good, the same "issue" exists for guix system subcommands, it
>> would be cool to have such functionality, but I would like to have those
>> changes to both guix system and guix home after wip-guix-home merged,
>> because backporting changes to rde is a little tedious.
>
> Your point is to hint both "guix system" and "guix home" in the same
> time because they share the same pattern. Right?
>
>> Also, it seems related to subcommands/--arguments discussion and maybe
>> better to talk about it in a separate thread.
>
> Yes, and from my understanding, your answer is keep consistency with
> "guix system". :-)
>
> Cheers,
> simon
Yep, corret (:
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
next prev parent reply other threads:[~2021-09-01 5:21 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-31 9:28 [bug#50296] [PATCH 0/2] Add 'guix home' command Andrew Tropin
[not found] ` <handler.50296.B.16304022327647.ack@debbugs.gnu.org>
2021-08-31 9:40 ` [bug#50296] [PATCH 1/2] scripts: Add 'guix home' Andrew Tropin
2021-08-31 10:53 ` zimoun
2021-08-31 12:12 ` Andrew Tropin
2021-08-31 13:09 ` zimoun
2021-09-01 5:20 ` Andrew Tropin [this message]
2021-08-31 9:40 ` [bug#50296] [PATCH 2/2] scripts: home: Add import subcommand Andrew Tropin
2021-08-31 10:46 ` [bug#50296] [PATCH 0/2] Add 'guix home' command zimoun
2021-08-31 12:03 ` Andrew Tropin
2021-08-31 11:13 ` bug#50296: " Oleg Pykhalov
2021-08-31 11:46 ` [bug#50296] " Andrew Tropin
2021-08-31 12:47 ` Andrew Tropin
2021-08-31 14:23 ` Oleg Pykhalov
2021-09-01 5:36 ` Andrew Tropin
2021-09-09 6:10 ` Andrew Tropin
2021-09-09 17:45 ` Oleg Pykhalov
2021-09-10 5:31 ` Andrew Tropin
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=87lf4gzxbi.fsf@trop.in \
--to=andrew@trop.in \
--cc=50296@debbugs.gnu.org \
--cc=zimon.toutoune@gmail.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/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.