all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Preparing for an alpha release
@ 2012-12-16 16:56 Ludovic Courtès
  2012-12-16 18:43 ` Nikita Karetnikov
  0 siblings, 1 reply; 3+ messages in thread
From: Ludovic Courtès @ 2012-12-16 16:56 UTC (permalink / raw)
  To: bug-guix

Hello Guixers!

ROADMAP says Guix 0.1 will be released in December.  Given that I’ll be
on vacation starting from next week, and that there are still some
glitches that seem worth fixing, ROADMAP may well be wrong.  ;-)

Roughly, here’s what I’d like to fix before the release:

  • things related to guix-daemon, such as Andreas’ problem with build
    users;

  • things related to command-line tools, such as options documented and
    not implemented in ‘guix-package’;

  • use on non-NixOS distros; in particular, it would be great if we
    everything can be built in chroots lacking /bin/sh.

Anything else?

With this in mind, we should be able to release by mid-January.

It’s an alpha release, and there’ll be some features missing compared to
Nix.  For instance, the daemon will not support substituters (the
mechanism that allows it to get pre-built binaries from the build farm).
Yet I think it’s already a useful piece of software, and it gives a good
idea of where the project is heading to.

Thoughts?

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Preparing for an alpha release
  2012-12-16 16:56 Preparing for an alpha release Ludovic Courtès
@ 2012-12-16 18:43 ` Nikita Karetnikov
  2012-12-16 21:54   ` Ludovic Courtès
  0 siblings, 1 reply; 3+ messages in thread
From: Nikita Karetnikov @ 2012-12-16 18:43 UTC (permalink / raw)
  To: bug-guix

> things related to command-line tools, such as options documented and
> not implemented in ‘guix-package’;

I'd like to implement '--roll-back' and '--search'.

Questions:

scheme@(guile-user)> ,use (guix-package)
scheme@(guile-user)> %current-profile
$1 = "/nix/var/nix/profiles/per-user/root/guix-profile"
scheme@(guile-user)> %profile-directory
$2 = "/nix/var/nix/profiles/per-user/root"
scheme@(guile-user)> %user-environment-directory
$3 = "/root/.guix-profile"

'ls' doesn't list the above. Why?

# ls -a /nix/var/nix/profiles/per-user/root/
.  ..  channels  channels-1-link
# ls -a /root
.   .aptitude      .bashrc  .gitconfig  .nix-channels  .profile
..  .bash_history  .cache   .gnupg      .nix-defexpr

How should '--roll-back' work? Does Guix support multiple profiles?

Nix uses the following scheme. [1]

# ls /nix/var/nix/profiles/
default          default-2-link  default-5-link  default-8-link
default-10-link  default-3-link  default-6-link  default-9-link
default-1-link   default-4-link  default-7-link  per-user

What function should be used to access the pointee of 'guix-profile'?

I assume that it should work like this:

1. Get the pointee of 'guix-profile'.

2. Parse the name of the pointee.

3. Decrement the number and save that as '%current-profile'.

Should 'guix-package' also support '--switch-generation',
'--list-generations', and '--switch-profile'? [1]

How to implement '--search'?

One option is to wrap around 'nix-env --search', but there are two
problems with this approach:

1. I don't know how to call it from Guile.

2. We don't want to depend on 'nix-env', do we?

I apologize if my questions sound naive, but I still have a vague
understanding of the internals.

Nikita

[1] http://hydra.nixos.org/build/3488542/download/1/manual/#sec-profiles

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Preparing for an alpha release
  2012-12-16 18:43 ` Nikita Karetnikov
@ 2012-12-16 21:54   ` Ludovic Courtès
  0 siblings, 0 replies; 3+ messages in thread
From: Ludovic Courtès @ 2012-12-16 21:54 UTC (permalink / raw)
  To: Nikita Karetnikov; +Cc: bug-guix

Hello,

Nikita Karetnikov <nikita.karetnikov@gmail.com> skribis:

>> things related to command-line tools, such as options documented and
>> not implemented in ‘guix-package’;
>
> I'd like to implement '--roll-back' and '--search'.

Cool!

> Questions:
>
> scheme@(guile-user)> ,use (guix-package)
> scheme@(guile-user)> %current-profile
> $1 = "/nix/var/nix/profiles/per-user/root/guix-profile"
> scheme@(guile-user)> %profile-directory
> $2 = "/nix/var/nix/profiles/per-user/root"
> scheme@(guile-user)> %user-environment-directory
> $3 = "/root/.guix-profile"
>
> 'ls' doesn't list the above. Why?

$1 gets created only once you’ve run ‘guix-package --install’.

And $3 has to be created manually, currently.  Probably ‘guix-package’
should create it automatically.  It’s just a fixed symlink to $1.

> How should '--roll-back' work?

Just change /nix/var/nix/profiles/per-user/root/guix-profile to point to
/nix/var/nix/profiles/per-user/root/guix-PREV-profile, where PREV is the
previous generation number (see ‘latest-profile-number’ in guix-package.)

> Does Guix support multiple profiles?

Yes: see the --profile option of guix-package.  Same as for nix-env.

> Nix uses the following scheme. [1]
>
> # ls /nix/var/nix/profiles/
> default          default-2-link  default-5-link  default-8-link
> default-10-link  default-3-link  default-6-link  default-9-link
> default-1-link   default-4-link  default-7-link  per-user
>
> What function should be used to access the pointee of 'guix-profile'?

You could use (readlink %current-profile), and then the %PROFILE-RX
regexp of ‘latest-profile-number’ to extract the profile number.

> I assume that it should work like this:
>
> 1. Get the pointee of 'guix-profile'.
>
> 2. Parse the name of the pointee.
>
> 3. Decrement the number and save that as '%current-profile'.

Yes, that’s the idea.  And then (delete-file %current-profile) and
(symlink new-profile %current-profile).

> Should 'guix-package' also support '--switch-generation',

Likewise: delete %current-profile and make it point elsewhere.

> '--list-generations',

List the files in %PROFILE-DIRECTORY matching %PROFILE-RX.

> and '--switch-profile'? [1]

Not sure about this one, but it’s basically changing a symlink’s target
again.

> How to implement '--search'?

User would provide a regexp, and you would use ‘fold-packages’ to
traverse all the packages and pattern-match each synopsis and
description, and return the matching packages.

How does that sound?

Thanks!

Ludo’.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-12-16 21:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-16 16:56 Preparing for an alpha release Ludovic Courtès
2012-12-16 18:43 ` Nikita Karetnikov
2012-12-16 21:54   ` Ludovic Courtès

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.