all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* git guix checkout automation for contributors
@ 2022-09-25 14:06 Danny Milosavljevic
  2022-09-25 15:04 ` Danny Milosavljevic
  2022-10-01 17:18 ` Ludovic Courtès
  0 siblings, 2 replies; 10+ messages in thread
From: Danny Milosavljevic @ 2022-09-25 14:06 UTC (permalink / raw)
  To: Guix-devel

[-- Attachment #1: Type: text/plain, Size: 2076 bytes --]

Hi,

So there were some comments on https://news.ycombinator.com/item?id=32960308
about getting started with contributing to Guix.

It turns out that the barrier of entry for editing existing packages is
kinda high (I tried it myself--putting myself into the mindset of a
beginner).

For example:

(1) Install the guix system
(2) Log in as regular user
(3) guix edit nano
(4) It opens a file from /gnu/store that you cannot edit.

Uhh. That's... not ideal. Maybe instead error out with a hint on what you need
to do in order to provide a local checkout? Or do we want viewing to work?

Ok, so let's say we are a little more knowledgeable:

(1) Install the guix system
(2) Log in as regular user
(3a) if [ ! -d src ]
  then
    mkdir src
    cd src
  else
    cd src
  fi \
  && if [ ! -d guix ]
  then
    git clone --depth=1 https://git.savannah.gnu.org/git/guix.git guix
  else
    (cd guix && git pull --rebase)
  fi \
  && cd guix \
  && guix shell -C -D guix -- ./bootstrap \
  && guix shell -C -D guix -- ./configure --localstatedir=/var --disable-daemon \
  && guix shell -C -D guix -- make -j5 \ <--- takes forever to build
  && ./pre-inst-env guix edit nano \
  && git add gnu/packages/*.scm

Ok, that worked.

But there are a lot of ways that can be done wrong.

Weird way it can be done wrong:

(1) install the guix system
(2) log in as regular user
(3b) git clone --depth=1 https://git.savannah.gnu.org/git/guix.git guix \
  && cd guix \
  && guix shell -C -D guix -- ./bootstrap \
  && guix shell -C -D guix -- ./configure --localstatedir=/var --disable-daemon \
  && ./pre-inst-env guix edit nano

It will open the file in /gnu/store . WTF? I'm pretty sure that that's a bug.

./pre-inst-env does exist--but it does some weird things if you don't
compile beforehand.

Also, can we put a variant of (3a) into a command "guix prepare-edit" or
something?
It has always bothered me how manual and magical-commandy it is otherwise
(what you actually need to do also changed over the years--not good).

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread
[parent not found: <mailman.14689.1664114844.1079.guix-devel@gnu.org>]

end of thread, other threads:[~2022-11-02 18:42 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-25 14:06 git guix checkout automation for contributors Danny Milosavljevic
2022-09-25 15:04 ` Danny Milosavljevic
2022-09-25 16:36   ` Maxime Devos
2022-10-01 17:18 ` Ludovic Courtès
2022-10-05  3:18   ` Maxim Cournoyer
2022-11-02 18:41   ` zimoun
     [not found] <mailman.14689.1664114844.1079.guix-devel@gnu.org>
2022-09-25 21:40 ` kiasoc5
2022-09-26 10:55   ` zimoun
2022-09-26 20:37     ` Josselin Poiret
2022-09-27  8:38       ` zimoun

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.