Home Explore Blog Models CI



nixpkgs

pkgs/tools/package-management/nix/modular/README.md
0e109112044a81d3e298da615c2683265113fc5789f75a660000000300000288
# `nix/modular`

This directory follows a directory structure similar to that in the upstream repo,
to make comparisons easier.

The files are maintained separately from the upstream repo, so differences are expected.

## Comparison

### No filesets

Using filesets with a fetched source would require "IFD", as the fetching happens in a derivation, but the filtering must come afterwards, and be done by the evaluator.

### `workDir` attribute

The Nixpkgs for Nix inherits the `workDir` attribute that determines the location of the subproject to build.
It is compared to this directory to produce the correct relative path, similar to upstream.

Chunks
c6d5d2e6 (1st chunk of `pkgs/tools/package-management/nix/modular/README.md`)
Title: `nix/modular` Directory Overview
Summary
This document describes the `nix/modular` directory, noting its structural resemblance to an upstream repository for easier comparison, despite its files being independently maintained. Key differences highlighted include the avoidance of "filesets" with fetched sources to prevent Implicit Function Derivation (IFD), and the use of the inherited `workDir` attribute in Nixpkgs for Nix to determine the build location, mirroring the upstream method.