From mboxrd@z Thu Jan 1 00:00:00 1970 From: swedebugia Subject: CLI reorganization revisited (Was: Re: Another cli interface for guix/sd) Date: Mon, 5 Nov 2018 22:24:31 +0100 Message-ID: <54f45908-3390-b95e-d52a-eb34e6caf239@riseup.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="------------1F4ACA6DBDFE26562B605AAB" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:34522) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gJmX2-0003Oj-Se for guix-devel@gnu.org; Mon, 05 Nov 2018 16:35:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gJmMS-0003IF-5m for guix-devel@gnu.org; Mon, 05 Nov 2018 16:24:44 -0500 Received: from mx1.riseup.net ([198.252.153.129]:40786) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gJmMP-0003F2-Fa for guix-devel@gnu.org; Mon, 05 Nov 2018 16:24:38 -0500 Received: from piha.riseup.net (piha-pn.riseup.net [10.0.1.163]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.riseup.net (Postfix) with ESMTPS id 8886E1A0151 for ; Mon, 5 Nov 2018 13:24:34 -0800 (PST) Received: from [127.0.0.1] (localhost [127.0.0.1]) by piha.riseup.net with ESMTPSA id F38D864B88 for ; Mon, 5 Nov 2018 13:24:33 -0800 (PST) Content-Language: en-US List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org This is a multi-part message in MIME format. --------------1F4ACA6DBDFE26562B605AAB Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable ------------------------------------------------------------------------ *From*: Ludovic Court=C3=A8s *Subject*: Re: Another cli interface for guix/sd *Date*: Thu, 30 Mar 2017 16:46:33 +0200 *User-agent*: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) > For a start, I think we should focus on =E2=80=98guix package=E2=80=99 = since there=E2=80=99s > consensus that it does too much. What do we leave in it? What do we > take out? Should we add a =E2=80=98guix profile=E2=80=99 command to de= al with > generations, but not to install/remove/upgrade packages? > > Similarly, as has been discussed before, we should probably add =E2=80=98= guix > install=E2=80=99, =E2=80=98guix remove=E2=80=99, and =E2=80=98guix upgr= ade=E2=80=99 aliases that do what we > would expect. > > Thoughts? +1 Did anything happen after this message above by Ludo'? (source https://li= sts.gnu.org/archive/html/guix-devel/2017-03/msg00845.html) I like the idea of taking generation and profile out of package. I would like to go ahead preparing a patch for the aliases for =E2=80=98g= uix install=E2=80=99, =E2=80=98guix remove=E2=80=99, and =E2=80=98guix up= grade=E2=80=99. Any thoughts? --=20 Cheers Swedebugia --------------1F4ACA6DBDFE26562B605AAB Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable
From: Ludovic Court=C3=A8s
Subject: Re: Another cli interface for guix/sd
Date: Thu, 30 Mar 2017 16:46:33 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux= )

For a start, I think we should focus on =E2=80=98guix package=E2=80=
=99 since there=E2=80=99s
consensus that it does too much.  What do we leave in it?  What do we
take out?  Should we add a =E2=80=98guix profile=E2=80=99 command to deal=
 with
generations, but not to install/remove/upgrade packages?

Similarly, as has been discussed before, we should probably add =E2=80=98=
guix
install=E2=80=99, =E2=80=98guix remove=E2=80=99, and =E2=80=98guix upgrad=
e=E2=80=99 aliases that do what we
would expect.

Thoughts?
+1 Did anything happen after this message above by Ludo'? (source https://lists.gnu.org/archive/html/guix-devel= /2017-03/msg00845.html) I like the idea of taking generation and profile out of package. I would like to go ahead preparing a patch for the aliases for =E2=80=98g= uix install=E2=80=99, =E2=80=98guix remove=E2=80=99, and =E2=80=98guix up= grade=E2=80=99. Any thoughts?=20
--=20
Cheers
Swedebugia
--------------1F4ACA6DBDFE26562B605AAB-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: CLI reorganization revisited Date: Tue, 06 Nov 2018 15:24:35 +0100 Message-ID: <87va5az3ks.fsf@gnu.org> References: <54f45908-3390-b95e-d52a-eb34e6caf239@riseup.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:50828) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gK2Hh-0002Eq-C8 for guix-devel@gnu.org; Tue, 06 Nov 2018 09:24:50 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gK2Hd-0005uT-2B for guix-devel@gnu.org; Tue, 06 Nov 2018 09:24:48 -0500 In-Reply-To: <54f45908-3390-b95e-d52a-eb34e6caf239@riseup.net> (swedebugia's message of "Mon, 5 Nov 2018 22:24:31 +0100") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: swedebugia Cc: guix-devel@gnu.org Hello, swedebugia skribis: > ------------------------------------------------------------------------ > *From*: Ludovic Court=C3=A8s > *Subject*: Re: Another cli interface for guix/sd > *Date*: Thu, 30 Mar 2017 16:46:33 +0200 > *User-agent*: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) > > >> For a start, I think we should focus on =E2=80=98guix package=E2=80=99 s= ince there=E2=80=99s >> consensus that it does too much. What do we leave in it? What do we >> take out? Should we add a =E2=80=98guix profile=E2=80=99 command to dea= l with >> generations, but not to install/remove/upgrade packages? >> >> Similarly, as has been discussed before, we should probably add =E2=80= =98guix >> install=E2=80=99, =E2=80=98guix remove=E2=80=99, and =E2=80=98guix upgra= de=E2=80=99 aliases that do what we >> would expect. >> >> Thoughts? > +1 > Did anything happen after this message above by Ludo'? (source https://li= sts.gnu.org/archive/html/guix-devel/2017-03/msg00845.html) No. > I like the idea of taking generation and profile out of package. Yeah, I=E2=80=99m not so sure. :-) > I would like to go ahead preparing a patch for the aliases for =E2=80=98g= uix install=E2=80=99, =E2=80=98guix remove=E2=80=99, and =E2=80=98guix upgr= ade=E2=80=99. That would be sweet! Thanks, Ludo=E2=80=99. From mboxrd@z Thu Jan 1 00:00:00 1970 From: swedebugia Subject: Re: CLI reorganization revisited Date: Thu, 8 Nov 2018 23:18:55 +0100 Message-ID: <365ea0c0-a3b5-69de-398c-af216ed55975@riseup.net> References: <54f45908-3390-b95e-d52a-eb34e6caf239@riseup.net> <87va5az3ks.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------89B89B5FA2AB5C07914BED62" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:40053) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gKsYW-0002HO-3e for guix-devel@gnu.org; Thu, 08 Nov 2018 17:13:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gKsYN-0005l0-Q9 for guix-devel@gnu.org; Thu, 08 Nov 2018 17:13:36 -0500 In-Reply-To: <87va5az3ks.fsf@gnu.org> Content-Language: sv-FI List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: =?UTF-8?Q?Ludovic_Court=c3=a8s?= , guix-devel This is a multi-part message in MIME format. --------------89B89B5FA2AB5C07914BED62 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Hi :) On 2018-11-06 15:24, Ludovic Court=C3=A8s wrote: > Hello, > > swedebugia skribis: > >> I would like to go ahead preparing a patch for the aliases for =E2=80=98= guix install=E2=80=99, =E2=80=98guix remove=E2=80=99, and =E2=80=98guix u= pgrade=E2=80=99. > That would be sweet! I gave it a go but did not get that far. :p This patch errors out with: $ ./pre-inst-env guix install ice-9/boot-9.scm:3356:22: Syntax error: /home/sdb/guix-tree/guix/scripts/install.scm:31:2: define-module:=20 expected keyword arg in subform (guix-install) of (define-module (guix=20 scripts install) #:use-module ((guix ui) #:hide=20 (display-profile-content)) #:use-module (guix scripts) #:use-module=20 (guix scripts package) (guix-install)) I do not understand how args work. Is this documented somewhere? Also I do not understand this form: (define (guix-describe . args) =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ^ What is the role of the dot? I'm probably in way over my head here :D Cheers Swedebugia --------------89B89B5FA2AB5C07914BED62 Content-Type: text/x-patch; name="0001-WIP-Add-guix-install.patch" Content-Disposition: attachment; filename="0001-WIP-Add-guix-install.patch" Content-Transfer-Encoding: quoted-printable >From 82a844c8c37b9a969e332ff19a87aa857881b039 Mon Sep 17 00:00:00 2001 From: swedebugia Date: Thu, 8 Nov 2018 22:57:49 +0100 Subject: [PATCH] WIP: 'Add guix install'. --- Makefile.am | 2 ++ guix/scripts/install.scm | 41 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 guix/scripts/install.scm diff --git a/Makefile.am b/Makefile.am index c63b65ba5..2dfbef006 100644 --- a/Makefile.am +++ b/Makefile.am @@ -12,6 +12,7 @@ # Copyright =C2=A9 2018 Nils Gillmann # Copyright =C2=A9 2018 Julien Lepiller # Copyright =C2=A9 2018 Oleg Pykhalov +# Copyright =C2=A9 2018 swedebugia # # This file is part of GNU Guix. # @@ -196,6 +197,7 @@ MODULES =3D \ guix/scripts/build.scm \ guix/scripts/archive.scm \ guix/scripts/import.scm \ + guix/scripts/install.scm \ guix/scripts/package.scm \ guix/scripts/gc.scm \ guix/scripts/hash.scm \ diff --git a/guix/scripts/install.scm b/guix/scripts/install.scm new file mode 100644 index 000000000..ebfa819a7 --- /dev/null +++ b/guix/scripts/install.scm @@ -0,0 +1,41 @@ + +;;; GNU Guix --- Functional package management for GNU +;;; Copyright =C2=A9 2018 swedebugia + +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (a= t +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see . + +;;; Commentary: +;;; +;;; Alias for "guix package -i" +;;; Needs to be in its own file because of (command-files) in guix/ui.sc= m +;;; + +(define-module (guix scripts install) + #:use-module ((guix ui) #:hide (display-profile-content)) + #:use-module (guix scripts) + #:use-module (guix scripts package) + (guix-install)) + +;;; +;;; Entry point. +;;; + +(define (guix-install . args) +;; How do we pass everything over to (guix scripts package)? + (display args) + (newline) + (display "swedebugia was here")) --=20 2.18.0 --------------89B89B5FA2AB5C07914BED62-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: Amirouche Boubekki Subject: Re: CLI reorganization revisited Date: Thu, 8 Nov 2018 23:46:07 +0100 Message-ID: References: <54f45908-3390-b95e-d52a-eb34e6caf239@riseup.net> <87va5az3ks.fsf@gnu.org> <365ea0c0-a3b5-69de-398c-af216ed55975@riseup.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000d144c8057a2f0096" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:56173) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gKt4R-0003qE-Vw for guix-devel@gnu.org; Thu, 08 Nov 2018 17:46:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gKt4R-00010w-26 for guix-devel@gnu.org; Thu, 08 Nov 2018 17:46:39 -0500 In-Reply-To: <365ea0c0-a3b5-69de-398c-af216ed55975@riseup.net> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: swedebugia@riseup.net Cc: guix-devel --000000000000d144c8057a2f0096 Content-Type: text/plain; charset="UTF-8" > > I do not understand how args work. Is this documented somewhere? > > Also I do not understand this form: > > (define (guix-describe . args) > ^ > What is the role of the dot? > The dot serve as a separator between 'required' argument and 'rest' arguments which is always a list that might be empty. In the above case everything passed to the procedure guix-describe is considered part of args. HTH --000000000000d144c8057a2f0096 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I do not understand how args work. Is this documented somewhere?

Also I do not understand this form:

(define (guix-describe . args)
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ^
What is the role of the dot?


=
The dot serve as a separator between 'required' argument and &= #39;rest' arguments which is always a list that might be empty.
In the above case everything passed to the procedure guix-describe = is considered part of args.

HTH
--000000000000d144c8057a2f0096-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: swedebugia Subject: Re: CLI reorganization revisited Date: Fri, 9 Nov 2018 00:13:19 +0100 Message-ID: References: <54f45908-3390-b95e-d52a-eb34e6caf239@riseup.net> <87va5az3ks.fsf@gnu.org> <365ea0c0-a3b5-69de-398c-af216ed55975@riseup.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="------------A8C69BBE6D17F9BAF3546F5A" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:56391) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gL0TC-000474-KH for guix-devel@gnu.org; Fri, 09 Nov 2018 01:40:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gL0Sz-0001z7-CY for guix-devel@gnu.org; Fri, 09 Nov 2018 01:40:35 -0500 In-Reply-To: Content-Language: sv-FI List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Amirouche Boubekki Cc: guix-devel This is a multi-part message in MIME format. --------------A8C69BBE6D17F9BAF3546F5A Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable On 2018-11-08 23:46, Amirouche Boubekki wrote: > > I do not understand how args work. Is this documented somewhere? > > Also I do not understand this form: > > (define (guix-describe . args) > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ^ > What is the role of the dot? > > > > The dot serve as a separator between 'required' argument and 'rest'=20 > arguments which is always a list that might be empty. > In the above case everything passed to the procedure guix-describe is=20 > considered part of args. Thank you! I just saw that GNU Scheme implemented that as keyword: #optional! This is more clear for the reader/beginner actually. ;-) --=20 Cheers Swedebugia --------------A8C69BBE6D17F9BAF3546F5A Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable



On 2018-11-08 23:46, Amirouche Boubekk= i wrote:
I do not understand how args work. Is this documented somewhere?

Also I do not understand this form:

(define (guix-describe . args)
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ^
What is the role of the dot?


The dot serve as a separator between 'required' argument and 'rest' arguments which is always a list that might be empty.
In the above case everything passed to the procedure guix-describe is considered part of args.
Thank you!

I just saw that GNU Scheme implemented that as keyword: #optional!
This is more clear for the reader/beginner actually. ;-)

--
Cheers Swedebugia
--------------A8C69BBE6D17F9BAF3546F5A--