I installed nix as per the instructions: Download Nix / NixOS | Nix & NixOS and have
dom@Ember ~ % nix-shell -p nix-info --run "nix-info -m"
nix-shell -p nix-info --run "nix-info -m"
- system: `"aarch64-darwin"`
- host os: `Darwin 22.5.0, macOS 13.4`
- multi-user?: `yes`
- sandbox: `no`
- version: `nix-env (Nix) 2.16.1`
- channels(root): `"nixpkgs"`
- nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixpkgs`
So note the root
user. If I try to install via nix-env
then
dom@Ember ~ % nix-env -i direnv
nix-env -i direnv
installing 'direnv-2.32.3'
error: opening lock file '/nix/var/nix/profiles/per-user/dom/profile.lock': No such file or directory
And indeed there is no dom
; there is only root
.