A modern, delicious implementation of the Nix package manager, focused on correctness, usability, and growth — and committed to doing right by its community https://lix.systems
Find a file
Raito Bezarius ef94901156 libstore/build: pathContentsGood is physical path aware now
`pathContentsGood` is used to assess the validity of a path as part of
derivation goals *in repair mode*.

When repair is used with a diverted store, i.e. a store where
fsPath(toRealPath(s)) != fsPath(s) for s a store path, this result in
utterly broken behavior because it will attempt to assess the goodness
of the *logical* store locations, most of the time: /nix/store/...

So, if you are repairing your system using a live NixOS ISO. Your ISO
contains a `/nix/store` (assumed to be good) and you repair your system
which is rooted at /mnt and contains its own /nix/store, that is, a Nix
store at /mnt/nix/store.

Performing the following operation `nix-store --verify --repair --store
/mnt` will assess the contents goodness of the ISO's Nix store.

To avoid this, we assess the path existence of the *physical path*, aka
the result of `store.toRealPath` applied to a *logical* store path
string representation and we verify the hash of the *physical path*.

The error messages are not taken care of in this CL as those are purely
cosmetic and helps the user understand what is going on.

Fixes #892.

Change-Id: Ib9e0153cb5683edcf37f1963ebf065ceba5e5dfb
Signed-off-by: Raito Bezarius <raito@lix.systems>
2025-07-27 01:42:41 +02:00
.github fix: docs issue template was busted 2024-09-14 19:28:46 +00:00
bench bench: rewrite in python, add instruction count profiling 2025-03-14 19:24:21 +01:00
contrib function-trace: always show the trace 2019-09-18 23:23:21 +02:00
doc docs: properly explain conversions in nix eval --json/--raw options. 2025-07-26 20:05:54 +00:00
lix libstore/build: pathContentsGood is physical path aware now 2025-07-27 01:42:41 +02:00
maintainers Draft of OWNERS 2025-07-14 18:20:47 -07:00
meson build: add capnp compiler wrapper 2025-07-15 06:40:48 +00:00
misc Draft of OWNERS 2025-07-14 18:20:47 -07:00
nix-support editline: Vendor cl/1883 patch to recognize Alt+Left/Alt+Right 2024-09-11 09:35:00 -07:00
perl perl: ensure that stores are destroyed after aio roots 2025-06-17 14:34:05 +02:00
releng Draft of OWNERS 2025-07-14 18:20:47 -07:00
scripts Draft of OWNERS 2025-07-14 18:20:47 -07:00
subprojects Draft of OWNERS 2025-07-14 18:20:47 -07:00
tests libstore/build: pathContentsGood is physical path aware now 2025-07-27 01:42:41 +02:00
.clang-format Add pre-commit checks 2024-03-29 22:57:40 -07:00
.clang-tidy libutil: trace unwinding through async tasks 2025-04-06 12:14:51 +02:00
.dir-locals.el .dir-locals.el: Set c-block-comment-prefix 2020-07-10 11:21:06 +02:00
.editorconfig .editorconfig: json: init with 4 space indent 2025-05-15 15:11:57 -07:00
.envrc .envrc: remove MAKEFLAGS and use clang environment by default 2024-06-25 12:36:18 -06:00
.gitignore fix codestyle of functional2 2025-05-10 21:13:45 +02:00
.mailmap add .mailmap 2024-11-04 13:46:10 +01:00
.this-is-lix devShell: guard against running from another directory 2024-06-24 13:41:38 -07:00
Cargo.lock rowan: 0.15.15 -> 0.15.16 2024-08-26 11:34:43 -07:00
Cargo.toml fix tooling after include reorganization 2024-11-19 22:55:32 +00:00
CONTRIBUTING.md chore: re-work the contribution guide 2024-05-07 01:28:35 +00:00
COPYING Add pre-commit checks 2024-03-29 22:57:40 -07:00
default.nix Format Nix code with nixfmt 2024-04-08 13:00:00 -07:00
docker.nix flake/inputs: 24.11-small -> 25.05-small 2025-06-13 18:15:47 +00:00
flake.lock flake/inputs: 24.11-small -> 25.05-small 2025-06-13 18:15:47 +00:00
flake.nix Use lowdown 2.0.2 in CI 2025-07-23 16:48:52 +02:00
justfile tests/functional2: add runner to justfile 2025-06-01 20:19:37 +02:00
meson.build build: simplify -Dnix-eval-jobs handling 2025-07-26 19:38:35 +00:00
meson.options libstore: use pasta for FODs if available 2025-06-24 10:49:49 +00:00
OWNERS Draft of OWNERS 2025-07-14 18:20:47 -07:00
package.nix packaging: stop copying unnecessary boost libraries 2025-07-26 20:04:59 +00:00
README.md Fix typos in documentation 2025-03-18 04:20:00 +00:00
shell.nix Use locked flake-compat in shell.nix 2024-12-30 07:25:23 -08:00
treefmt.toml functional2: Added ruff formatter 2025-05-10 22:14:10 +02:00
version.json version.json: 2.93.0 -> 2.94.0-dev 2025-05-11 16:51:25 -07:00

Lix

Lix is an implementation of Nix, a powerful package management system for Linux and other Unix systems that makes package management reliable and reproducible.

Read more about us at https://lix.systems.

Installation

On Linux and macOS the easiest way to install Lix is to run the following shell command (as a user other than root):

$ curl -sSf -L https://install.lix.systems/lix | sh -s -- install

For systems that already have a Nix implementation installed, such as NixOS systems, read our install page

Building And Developing

See our Hacking guide in our manual for instruction on how to set up a development environment and build Lix from source.

Additional Resources

License

Lix is released under LGPL-2.1-or-later.