[Nix-dev] updates and nix-env -i vs nix-env -iA (was: Re: python-x.y.z-wrapper vs python-x.y.z-full)

Florian Friesdorf flo at chaoflow.net
Fri Oct 21 20:17:47 CEST 2011


Hi Peter,

<#secure method=pgpmime mode=sign>
On Fri, 21 Oct 2011 19:43:02 +0200, Peter Simons <simons at cryp.to> wrote:
> Hi Florian,
> 
>  > 2.7.1 is considered to be smaller than 2.7.1-wrapper; installing and
>  > keeping 2.7.1 via nix-env is not possible. As the -wrapper versions
>  > are the full python versions, which mostly everybody would want to
>  > install, that's ok.
> 
> yes, I completely agree. The way nix-env chooses updates is fine most of
> the time, but it's bad in some case where one would like to keep a
> variant that's considered "older".
> 
>  > However, having installed 'nix-dev -iA nixpkgs_sys.python', an upgrade
>  > will lead to nixpkgs_sys.pythonFull, which i think is confusing.
> 
> I've found that buildEnv provides a decent solution to that problem:
> 
>   http://nixos.org/wiki/Howto_keep_multiple_packages_up_to_date_at_once

Yes, I agree.

Could we, apart from having buildEnv, do something about nix-env
remembering how things were installed?

As far as I understand, "nix-env -u" does not care about attr-paths, but
searches for updates based on attr-name.

1) nix-env -i python
- attr-path: pkgs.pythonFull

2) nix-env -i python-2.7.1
- attr-path: pkgs.python27 and pkgs.python

3) nix-env -iA pkgs.python27
- attr-path: pkgs.python27

"nix-env -u" could remember the attr-path and use that to search for
updates.

This behaviour could also be triggered explicitly by "nix-env -iA".


regards
florian
-- 
Florian Friesdorf <flo at chaoflow.net>
  GPG FPR: 7A13 5EEE 1421 9FC2 108D  BAAF 38F8 99A3 0C45 F083
Jabber/XMPP: flo at chaoflow.net
IRC: chaoflow on freenode,ircnet,blafasel,OFTC


More information about the nix-dev mailing list