Note that the nix eval function is not stable yet, and it seems that the flake version of nix eval breaks some common patterns. For now, the stable way of evaluating stuff is to use nix-instantiate (let me know if somebody knows how to condensate the with import ... stuff):
Good to know, thanks. But any idea if it’s possible to remove the quotes "...", for example in this command? I’m looking for an equivalent of --raw in nix eval I guess.
$ nix-instantiate --eval -E 'builtins.fetchTarball {url = https://github.com/NixOS/nixpkgs/archive/925ae0dee63.tar.gz; sha256 = "1g3kkwyma23lkszdvgb4dn91g35b082k55ys8azc7j4s6vxpzmaw"; }'
"/nix/store/m59d3v89nhp9207hgvf6v21wxq7lhq64-source"
# I would prefer:
/nix/store/m59d3v89nhp9207hgvf6v21wxq7lhq64-source
@samuela: you mean nix eval? If yes, the problem of nix eval is that it is not stable, and has different syntax between the flake version and the non flake one… which is quite annoying in scripts that need to be executed from both nix versions.