Skip to content

Instantly share code, notes, and snippets.

@steshaw
Last active September 15, 2020 20:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save steshaw/efa86a82e350896cfa5c30405d50add1 to your computer and use it in GitHub Desktop.
Save steshaw/efa86a82e350896cfa5c30405d50add1 to your computer and use it in GitHub Desktop.
$ nix-collect-garbage --delete-old # Delete all garbage and old generations.
[snip]
$ nix-env --list-generations
1007 2020-09-16 06:49:32 (current)
$ ls -alFh /home/steshaw/.nix-profile
lrwxrwxrwx 1 steshaw users 46 Jul 15 2019 /home/steshaw/.nix-profile -> /nix/var/nix/profiles/per-user/steshaw/profile/
$ ls -alFh /nix/var/nix/profiles/per-user/steshaw/profile
lrwxrwxrwx 1 steshaw users 17 Sep 16 06:49 /nix/var/nix/profiles/per-user/steshaw/profile -> profile-1007-link/
$ ls -alFh /nix/var/nix/profiles/per-user/steshaw/profile-1007-link
lrwxrwxrwx 1 steshaw users 60 Sep 16 06:49 /nix/var/nix/profiles/per-user/steshaw/profile-1007-link -> /nix/store/jzhb3wgjflgdb11v2k09lwf46a16lfzh-user-environment/
$ nix-env -iA nixpkgs.fzf
installing 'fzf-0.22.0'
these paths will be fetched (16.84 MiB download, 91.31 MiB unpacked):
/nix/store/2f6zzvixj3wsj81flbdcpc6fdscgx4ai-coreutils-8.31
/nix/store/4zby60235wjhj6kccglm1vcygf098li8-fzf-0.22.0-man
/nix/store/5b6853g3y2wvzc48l6921a6qcr55lqk2-perl-5.32.0
/nix/store/6ffp6xbr6j2ryqw2dafbbvv55ggq16iv-bash-4.4-p23
/nix/store/87alzvyjwdf2w1k6i6aj87pn4r0sdm6c-libunistring-0.9.10
/nix/store/dd3prkmzh7wjfz5cxnlym54vlh7ni89k-libidn2-2.3.0
/nix/store/fby8klnixr66d81cldxffq38x0q4bxa9-attr-2.4.48
/nix/store/hnsw79vycakpi4hgzsiayi235145rdfs-fzf-0.22.0
/nix/store/ilbwv6r37l626g7fg5s1g93k70zq3rp9-tzdata-2019c
/nix/store/jvjchabdmcxlwjhbiii5sy6d2hcg6z7r-glibc-2.31
/nix/store/xhb1hfzw71vkd7bdr5vjczlw0k78q1ni-acl-2.2.53
copying path '/nix/store/4zby60235wjhj6kccglm1vcygf098li8-fzf-0.22.0-man' from 'https://cache.nixos.org'...
copying path '/nix/store/87alzvyjwdf2w1k6i6aj87pn4r0sdm6c-libunistring-0.9.10' from 'https://cache.nixos.org'...
copying path '/nix/store/ilbwv6r37l626g7fg5s1g93k70zq3rp9-tzdata-2019c' from 'https://cache.nixos.org'...
copying path '/nix/store/dd3prkmzh7wjfz5cxnlym54vlh7ni89k-libidn2-2.3.0' from 'https://cache.nixos.org'...
copying path '/nix/store/jvjchabdmcxlwjhbiii5sy6d2hcg6z7r-glibc-2.31' from 'https://cache.nixos.org'...
copying path '/nix/store/fby8klnixr66d81cldxffq38x0q4bxa9-attr-2.4.48' from 'https://cache.nixos.org'...
copying path '/nix/store/6ffp6xbr6j2ryqw2dafbbvv55ggq16iv-bash-4.4-p23' from 'https://cache.nixos.org'...
copying path '/nix/store/xhb1hfzw71vkd7bdr5vjczlw0k78q1ni-acl-2.2.53' from 'https://cache.nixos.org'...
copying path '/nix/store/2f6zzvixj3wsj81flbdcpc6fdscgx4ai-coreutils-8.31' from 'https://cache.nixos.org'...
copying path '/nix/store/5b6853g3y2wvzc48l6921a6qcr55lqk2-perl-5.32.0' from 'https://cache.nixos.org'...
copying path '/nix/store/hnsw79vycakpi4hgzsiayi235145rdfs-fzf-0.22.0' from 'https://cache.nixos.org'...
building '/nix/store/cxhwvrgdmh8pc6agijywdx9yf02xprd9-user-environment.drv'...
created 2137 symlinks in user environment
$ ls -alFh /home/steshaw/.nix-profile
lrwxrwxrwx 1 steshaw users 46 Jul 15 2019 /home/steshaw/.nix-profile -> /nix/var/nix/profiles/per-user/steshaw/profile/
$ ls -alFh /nix/var/nix/profiles/per-user/steshaw/profile
lrwxrwxrwx 1 steshaw users 17 Sep 16 06:51 /nix/var/nix/profiles/per-user/steshaw/profile -> profile-1008-link/
$ ls -alFh /nix/var/nix/profiles/per-user/steshaw/profile-1008-link
lrwxrwxrwx 1 steshaw users 60 Sep 16 06:51 /nix/var/nix/profiles/per-user/steshaw/profile-1008-link -> /nix/store/bp1ff0l7akza0bxpr5qf3z74p20a1ij9-user-environment/
$ nix-env --list-generations
1007 2020-09-16 06:49:32
1008 2020-09-16 06:51:13 (current)
$ nix-env -e fzf
uninstalling 'fzf-0.22.0'
$ ls -alFh /home/steshaw/.nix-profile
lrwxrwxrwx 1 steshaw users 46 Jul 15 2019 /home/steshaw/.nix-profile -> /nix/var/nix/profiles/per-user/steshaw/profile/
$ ls -alFh /nix/var/nix/profiles/per-user/steshaw/profile
lrwxrwxrwx 1 steshaw users 17 Sep 16 06:51 /nix/var/nix/profiles/per-user/steshaw/profile -> profile-1009-link/
$ ls -alFh /nix/var/nix/profiles/per-user/steshaw/profile-1009-link
lrwxrwxrwx 1 steshaw users 60 Sep 16 06:51 /nix/var/nix/profiles/per-user/steshaw/profile-1009-link -> /nix/store/jzhb3wgjflgdb11v2k09lwf46a16lfzh-user-environment/
$ nix-env --list-generations
1007 2020-09-16 06:49:32
1008 2020-09-16 06:51:13
1009 2020-09-16 06:51:13 (current)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment