From mboxrd@z Thu Jan 1 00:00:00 1970 From: Zachary Kanfer Subject: Re: Is there a beginner's guide to using Guix with Scheme files? Date: Mon, 18 Apr 2016 00:06:30 -0400 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a113e436e6d3d2e0530ba7db1 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38907) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1as0Sa-0002oC-FF for help-guix@gnu.org; Mon, 18 Apr 2016 00:06:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1as0SY-0001BT-E6 for help-guix@gnu.org; Mon, 18 Apr 2016 00:06:52 -0400 Received: from mail-yw0-x235.google.com ([2607:f8b0:4002:c05::235]:33532) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1as0SY-0001AB-8w for help-guix@gnu.org; Mon, 18 Apr 2016 00:06:50 -0400 Received: by mail-yw0-x235.google.com with SMTP id t10so190846284ywa.0 for ; Sun, 17 Apr 2016 21:06:50 -0700 (PDT) In-Reply-To: List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: Catonano Cc: help-guix@gnu.org --001a113e436e6d3d2e0530ba7db1 Content-Type: text/plain; charset=UTF-8 Thanks for the response. I think one of the things I was confused about was that yes, the "average" user doesn't have to create packages, but can just make manifests. There isn't much discussion of manifests in the documentation, and I just missed it. But manifests are required for me to use Guix. If my best option is running `guix package -i emacs`, that's no advantage for me over `apt-get install emacs`. Your mileage may differ; this is my opinion. I'm similarly not installing GuixSD right now, but am using it on top of Ubuntu. On Sun, Apr 17, 2016 at 9:52 AM, Catonano wrote: > > > 2016-04-17 6:15 GMT+02:00 Zachary Kanfer : > >> I recently installed Guix, and I must admit I'm feeling somewhat lost. My >> goal is to not run `guix package -i` manually, but have a scheme file with >> my entire system configuration in it, and run `guix package -f >> /path/to/that/file` to install the programs I want on my computer. >> > > > Running "guiy package -i ..." > > is for the binary installation. That is when you install guix as a package > in a previously existing hosting system > > Otherwise, you can install GuixSD and it offers exaclty what Gyou want. > > You can have a scheme file specifying the disk layout, the users, the > services and so on and that's what will be installed > > You probably want to start from these instructions to have it installed > https://www.gnu.org/software/guix/manual/html_node/System-Installation.html > > Then, when you wiill want to arrange a scheme file with the list of > packages to be installed, you can come back here ;-) > >> >> >> I think what I want to start with is here ( >> http://www.gnu.org/software/guix/manual/guix.html#Programming-Interface), >> but I'm not sure. Looking at it is somewhat confusing, for a few reasons. >> I'm going to list what I see when reading this in hopes that the >> documentation can be improved. >> >> 1. It starts by discussing how to "define new packages". I would expect >> that I would only want to *use* packages, and that this would be done by >> the person adding the package to the software repository. >> > > Not necessarily. Arranging the build of a package can be demanding. Way > more demanding that just using the package. So it's not settled that the > person using the package will be the one who has prepared it for the > distribution > > The user most commonly will install packages provided by others. > Volunteers, mainly > > >> >> 2. The example given looks like a very complicated way of installing a >> simple package. >> > > That's exactly what I wrote. Those instructions are not aimed to casual > users wanting to USE a package. They are meant for the volunteers who > arrange the build of a package, so making it available to ALL the users of > the distribution > > >> There are many properties I don't care about when I'm installing software >> (homepage, synopsis /and/ description), and things I don't want to care >> about (arguments, inputs, build-system). To install a package on the >> command line, it's something simple like "apt-get install emacs". To use >> Guix, I have to write a 20-line program with a bunch of settings? >> > > No ;-) > > You just "guix package -i emacs" both on GuixSD AND on the binary > installation > > Properties and inputs are needed for building packages, not for using them > (not that knowing abiut those in detrimental, though) > > Anyway, if your model is > > "apt-get install emacs" > > I don't see why > > "guix package -i emacs" > > is so unsatisfying to you. They are not dramatically different > > >> >> 3. It goes on to discuss importing other people's package definitions ( >> http://www.gnu.org/software/guix/manual/guix.html#Invoking-guix-import). >> But it doesn't say how to do this in a Scheme file. I want my setup to be >> in a Scheme file, not in a bunch of commands I have to manually run. >> > > The instructions about how to import other people definitions, are exactly > meant to edit a scheme file ;-) > > Only, that scheme file is not made to install a package. It's made to > build it > > >> 4. It discusses running `guix build` to use the package definitions. This >> appears to be different than `guix package -i`, but I'm at a loss to say >> how. >> > > The first builds a package based on a definition written in scheme > > The second installs an already built package ;-) > > >> Am I missing a useful page somewhere in the documentation? Do I have some >> wrong assumptions about how Guix is used? Thanks for any help. >> > > I don't know about the documentation. As for wrong assumptions I hope I > have made things a bit clearer ;-) > --001a113e436e6d3d2e0530ba7db1 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Thanks for the response. I think one of the thin= gs I was confused about was that yes, the "average" user doesn= 9;t have to create packages, but can just make manifests. There isn't m= uch discussion of manifests in the documentation, and I just missed it.
=
But manifests are required for me to use Guix. If my best option = is running `guix package -i emacs`, that's no advantage for me over `ap= t-get install emacs`. Your mileage may differ; this is my opinion. I'm = similarly not installing GuixSD right now, but am using it on top of Ubuntu= .

= On Sun, Apr 17, 2016 at 9:52 AM, Catonano <catonano@gmail.com> wrote:


2016-04-1= 7 6:15 GMT+02:00 Zachary Kanfer <zkanfer@gmail.com>:
I recently installed Guix, and I must admit I'm = feeling somewhat lost. My goal is to not run `guix package -i` manually, bu= t have a scheme file with my entire system configuration in it, and run `gu= ix package -f /path/to/that/file` to install the programs I want on my comp= uter.
=

Running "guiy package -i ..."= ;

is for the binary installation. That is when you instal= l guix as a package in a previously existing hosting system

<= div>Otherwise, you can install GuixSD and it offers exaclty what Gyou want.=

You can have a scheme file specifying the disk layout, t= he users, the services and so on and that's what will be installed
<= br>
You probably want to start from these instructions to have it inst= alled
https://www.gnu.org/software/guix/m= anual/html_node/System-Installation.html

Then, when you wiill want to arrange a scheme file with the list = of packages to be installed, you can come back here ;-)
=C2=A0

I think what I want to start with is here (htt= p://www.gnu.org/software/guix/manual/guix.html#Programming-Interface), = but I'm not sure. Looking at it is somewhat confusing, for a few reason= s. I'm going to list what I see when reading this in hopes that the doc= umentation can be improved.

1. It starts by discuss= ing how to "define new packages". I would expect that I would onl= y want to *use* packages, and that this would be done by the person adding = the package to the software repository.

Not necessarily. Arranging the = build of a package can be demanding. Way more demanding that just using the= package. So it's not settled that the person using the package will be= the one who has prepared it for the distribution

The use= r most commonly will install packages provided by others. Volunteers, mainl= y
=C2=A0

2. The example given looks like a very complicated way of installing a sim= ple package.

That's exactly what I wrote. Those instructions are not aimed t= o casual users wanting to USE a package. They are meant for the volunteers = who arrange the build of a package, so making it available to ALL the users= of the distribution
=C2=A0
There are many properties I don't care about when I'm installing s= oftware (homepage, synopsis /and/ description), and things I don't want= to care about (arguments, inputs, build-system). To install a package on t= he command line, it's something simple like "apt-get install emacs= ". To use Guix, I have to write a 20-line program with a bunch of sett= ings?

<= div>No ;-)

You just "guix package -i emacs" bo= th on GuixSD AND on the binary installation

Properties an= d inputs are needed for building packages, not for using them (not that kno= wing abiut those in detrimental, though)

Anyway, if your = model is

"apt-get install emacs"

I don't see = why

"guix package -i emacs"

is so unsa= tisfying to you. They are not dramatically different
=C2=A0

3. It goes on to discuss importing othe= r people's package definitions (http://www.gn= u.org/software/guix/manual/guix.html#Invoking-guix-import). But it does= n't say how to do this in a Scheme file. I want my setup to be in a Sch= eme file, not in a bunch of commands I have to manually run.

The instructions about= how to import other people definitions, are exactly meant to edit a scheme= file ;-)

Only, that scheme file is not made to install a= package. It's made to build it
=C2=A0
=
4. It discusses running `guix build` to use the package definitions. T= his appears to be different than `guix package -i`, but I'm at a loss t= o say how.

The first builds a package based on a definition written in scheme
The second installs an already built package ;-)
=C2=A0
Am I missing a useful page somewhere i= n the documentation? Do I have some wrong assumptions about how Guix is use= d? Thanks for any help.

I don't know about the documentation. As f= or wrong assumptions I hope I have made things a bit clearer ;-)
<= /div>

--001a113e436e6d3d2e0530ba7db1--