From: ludo@gnu.org (Ludovic Courtès)
To: Nikita Karetnikov <nikita@karetnikov.org>
Cc: bug-guix@gnu.org
Subject: Re: guix-package --roll-back
Date: Sat, 05 Jan 2013 20:20:46 +0100 [thread overview]
Message-ID: <87vcbbqvw1.fsf@gnu.org> (raw)
In-Reply-To: <87obh43j7r.fsf@karetnikov.org> (Nikita Karetnikov's message of "Fri, 04 Jan 2013 13:18:43 -0500")
Hi,
Nikita Karetnikov <nikita@karetnikov.org> skribis:
> It depends on how profiles are stored. It turned out that there are
> several issues. By the way, what should I do to create a custom profile?
The only way to manipulate profiles is via ‘guix-package -p xxx’.
> Both 'profile-rx' and 'profile-number' work fine when '%current-profile'
> is used.
>
> scheme@(guile-user)> (define %current-profile "/nix/var/nix/profiles/per-user/root/guix-profile")
> scheme@(guile-user)> (profile-number %current-profile)
> $2 = "1"
> scheme@(guile-user)> (readlink %current-profile)
> $3 = "/nix/var/nix/profiles/per-user/root/guix-profile-1-link"
>
> But fail for other inputs.
That’s expected.
> Here is what I used to create a bogus custom profile.
>
> # cd /home
> # mkdir testdir
> # cd testdir
> # touch env-42
> # ln -s env-42 42-custom-profile
> # ln -s 42-custom-profile guix-profile
>
> [...]
>
> scheme@(guile-user)> (define custom-profile "/home/testdir/guix-profile")
> scheme@(guile-user)> (profile-number custom-profile)
> $7 = #f
Yeah, that’s expected. Basically, if you do
guix-package -p /dev/null --roll-back
it should fail with an error message saying that there is no previous
profile or something like that.
> So, what kinds of profiles should be supported? Maybe it's not possible
> to create something like 'custom-profile' and there is no need to
> bother.
There are two ways to use ‘guix-package’:
1. without -p, it uses the user’s default profile, by default
/nix/var/nix/profiles/per-user/$USER/guix-profile;
2. with -p, it uses the specified profile (see tests/guix-package.sh,
for an example).
Thanks,
Ludo’.
next prev parent reply other threads:[~2013-01-05 19:20 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-21 22:49 guix-package --roll-back Nikita Karetnikov
2012-12-29 23:09 ` Nikita Karetnikov
2012-12-29 23:13 ` Andreas Enge
2012-12-30 15:30 ` Ludovic Courtès
2013-01-01 13:57 ` Nikita Karetnikov
2013-01-01 22:58 ` Ludovic Courtès
2013-01-03 5:42 ` Nikita Karetnikov
2013-01-03 14:41 ` Ludovic Courtès
2013-01-04 18:18 ` Nikita Karetnikov
2013-01-05 19:20 ` Ludovic Courtès [this message]
2013-01-09 19:04 ` Nikita Karetnikov
2013-01-10 15:01 ` Nikita Karetnikov
2013-01-10 22:26 ` Ludovic Courtès
2013-01-11 5:48 ` Nikita Karetnikov
2013-01-11 13:39 ` Ludovic Courtès
2013-01-12 21:03 ` Nikita Karetnikov
2013-01-13 20:40 ` Ludovic Courtès
2013-01-16 21:34 ` Nikita Karetnikov
2013-01-17 21:47 ` Ludovic Courtès
2013-01-21 5:50 ` Nikita Karetnikov
2013-01-22 21:37 ` Ludovic Courtès
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=87vcbbqvw1.fsf@gnu.org \
--to=ludo@gnu.org \
--cc=bug-guix@gnu.org \
--cc=nikita@karetnikov.org \
/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.