1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-25 19:01:16 +02:00
Commit graph

2549 commits

Author SHA1 Message Date
Robert Hensing
78e2832d7d Edit rl-2.28
(cherry picked from commit 1ca3ee1287)
2025-04-06 17:03:38 -04:00
Robert Hensing
93248bd92c doc/rl-2.28: Add contributors
(cherry picked from commit fea87a94e6)
2025-04-06 17:03:36 -04:00
John Ericson
682a28a76b release notes: 2.28.0
(cherry picked from commit 703f0fbe74)
2025-04-06 17:03:34 -04:00
John Ericson
cc24766fa6 Expose the nix component in header include paths
For example, instead of doing

    #include "nix/store-config.hh"
    #include "nix/derived-path.hh"

Now do

    #include "nix/store/config.hh"
    #include "nix/store/derived-path.hh"

This was originally planned in the issue, and also recent requested by
Eelco.

Most of the change is purely mechanical. There is just one small
additional issue. See how, in the example above, we took this
opportunity to also turn `<comp>-config.hh` into `<comp>/config.hh`.
Well, there was already a `nix/util/config.{cc,hh}`. Even though there
is not a public configuration header for libutil (which also would be
called `nix/util/config.{cc,hh}`) that's still confusing, To avoid any
such confusion, we renamed that to `nix/util/configuration.{cc,hh}`.

Finally, note that the libflake headers already did this, so we didn't
need to do anything to them. We wouldn't want to mistakenly get
`nix/flake/flake/flake.hh`!

Progress on #7876
2025-04-01 11:40:42 -04:00
John Ericson
f3e1c47f47 Separate headers from source files
The short answer for why we need to do this is so we can consistently do
`#include "nix/..."`. Without this change, there are ways to still make
that work, but they are hacky, and they have downsides such as making it
harder to make sure headers from the wrong Nix library (e..g.
`libnixexpr` headers in `libnixutil`) aren't being used.

The C API alraedy used `nix_api_*`, so its headers are *not* put in
subdirectories accordingly.

Progress on #7876

We resisted doing this for a while because it would be annoying to not
have the header source file pairs close by / easy to change file
path/name from one to the other. But I am ameliorating that with
symlinks in the next commit.
2025-03-31 12:20:25 -04:00
Robert Hensing
6a192ec0cd C API: (breaking) remove nix-flake-c global init 2025-03-26 11:15:02 +00:00
Eelco Dolstra
be5a455a1a rl-2.27.md: Fix GitHub links
https://discourse.nixos.org/t/nix-2-27-0-released/62003/2?u=edolstra
2025-03-21 20:23:46 +01:00
oldshensheep
355a923e81 Improve the documentation of store path
# Conflicts:
#	doc/manual/source/protocols/store-path.md
2025-03-19 13:45:10 +08:00
John Ericson
f497711aa8
Merge pull request #12624 from KAction/store-path-doc
Improve the documentation of the store path protocol
2025-03-18 12:36:01 -04:00
Jörg Thalheim
af4c587ae3
Merge pull request #12596 from obsidiansystems/adv-attrs-organize
Advanced attributes organize
2025-03-12 23:21:48 +01:00
John Ericson
637aa0944d Advanced attributes organize
This is supposed to firstly improve the docs as they are, and secondly
hint at how the core conceptual information ought to be moved to the
store derivation section of the manual.

Co-authored-by: Jörg Thalheim <Mic92@users.noreply.github.com>
2025-03-12 17:45:51 -04:00
Dmitry Bogatov
affd9bbab7
Update doc/manual/source/protocols/store-path.md
Co-authored-by: John Ericson <git@JohnEricson.me>
2025-03-11 12:30:21 -04:00
Dmitry Bogatov
a0facb2aba Improve the documentation of the store path protocol
1. Fix confusing wording that might imply unnecessary double-hashing.
2. Add references to specifics of base-32 encoding.
3. Fix incorrect description that sha256 hash of `fingerprint` is
   truncated. "Truncated" is actual wording used in Nix theses, but it has
   unusual meaning, that is better conveyed by word "compressed", which is
   used by the reference C++ implementation.
4. Clarify details of base16 encoding.
2025-03-08 19:00:00 -05:00
Farid Zakaria
33493b9ead Fix minor documentation typos
Was reading the store chapter and came across a few small typos
and edits.
2025-03-07 23:07:03 -08:00
Valentin Gagarin
9c3dd34cfe doc: note that function bindings are accessible in default values
Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
2025-03-04 00:44:46 -05:00
Robert Hensing
efbd4c1ebb
Merge pull request #12442 from NixOS/store-derivation-options
Expand manual on derivation outputs
2025-03-03 23:11:51 +01:00
Robert Hensing
1e00d14c29 manual: Edit 2025-03-03 19:09:24 +01:00
John Ericson
2aa6e0f084 Expand manual on derivation outputs
Note, this includes some text adapted from from Eelco's dissertation
2025-02-27 02:13:36 -05:00
Eelco Dolstra
ed294a31f5 Add more release notes 2025-02-26 22:23:44 +01:00
Eelco Dolstra
1d89507656 Fix date 2025-02-26 22:05:50 +01:00
Eelco Dolstra
c5a64aefac Add contributors 2025-02-26 22:01:24 +01:00
Eelco Dolstra
4a7bdddc8b Edit release notes 2025-02-26 21:59:41 +01:00
Eelco Dolstra
80020b684f release notes: 2.27.0 2025-02-26 21:57:30 +01:00
Eelco Dolstra
779bb3b920 Include the Nix version in the title of the manual
This makes it easy to see at a glance what the version of the manual
is, e.g. "Nix 2.27.0 Reference Manual".
2025-02-24 14:49:58 +01:00
Silvan Mosberger
c19914f1ab doc: Fix ccacheStdenvPackages typo 2025-02-18 23:23:10 +01:00
Leandro Reina
8b89c453b9 Merge release notes 2025-02-14 13:54:19 +01:00
Leandro Reina
4a1d1c7f9f Add release note 2025-02-13 18:04:32 +01:00
Robert Hensing
693a38ae2e
Merge pull request #10153 from b-camacho/lfs
git-lfs support
2025-02-13 14:25:30 +01:00
Eelco Dolstra
ca7e686f4d
Merge pull request #12439 from MaxHearnden/cloexec
Set FD_CLOEXEC on sockets created by curl
2025-02-12 12:49:55 +01:00
Eelco Dolstra
2819d8b66a Add release note 2025-02-10 17:19:34 +01:00
Eelco Dolstra
c02fcebb30 Add release note 2025-02-10 16:08:03 +01:00
John Ericson
cafefed421 Rename to "content-address*ing* derivation"
"content-address*ed*" derivation is misleading because all derivations
are *themselves* content-addressed. What may or may not be
content-addressed is not derivation itself, but the *output* of the
derivation.

The outputs are not *part* of the derivation (for then the derivation
wouldn't be complete before we built it) but rather separate entities
produced by the derivation.

"content-adddress*ed*" is not correctly because it can only describe
what the derivation *is*, and that is not what we are trying to do.

"content-address*ing*" is correct because it describes what the
derivation *does* --- it produces content-addressed data.
2025-02-10 01:12:56 -05:00
John Ericson
e80d333777
Document Store Derivations and Deriving Paths (#12290)
This is a big step documenting the store layer on its own, separately from the evaluator (and `builtins.derivation`).

Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
2025-02-10 01:30:07 +00:00
MaxHearnden
12d2527276 Set FD_CLOEXEC on sockets created by curl
Curl creates sockets without setting FD_CLOEXEC/SOCK_CLOEXEC, this can
cause connections to remain open forever when using commands like `nix
shell`

This change sets the FD_CLOEXEC flag using a CURLOPT_SOCKOPTFUNCTION
callback.
2025-02-09 21:09:33 +00:00
silvanshade
7fd2125573
Add BLAKE3 to documentation 2025-02-05 17:49:15 -07:00
John Ericson
243467e14b More debugging documentation
There are a few things I think people should know, post-Meson.
2025-02-03 10:08:13 -05:00
Robert Hensing
96e550efc5 Format .nix files
... with nixfmt (rfc style)
2025-01-24 17:04:02 +01:00
Robert Hensing
ba6425a7d0 dev: Configure nixfmt (rfc style) 2025-01-24 17:02:50 +01:00
Robert Hensing
ace52b10c9 doc/building: Update for #11799
Reflect the shorter attribute name, changed in
f168a6e739
https://github.com/NixOS/nix/pull/11799
2025-01-24 12:41:26 +01:00
Eelco Dolstra
21f2e29176 Add release credits 2025-01-22 12:01:00 +01:00
Eelco Dolstra
617bf84518 Add a few more release notes 2025-01-22 11:55:20 +01:00
Eelco Dolstra
d8dbb71c92 release notes: 2.26.0 2025-01-22 11:45:04 +01:00
Ilja Kotirinta
c59aa3ec87 Remove character not needed for a command 2025-01-20 14:03:29 +02:00
Eelco Dolstra
17b6557c03
Merge pull request #12275 from andrewhamon/ah/set-priority-nix-env-install
nix-env: add a --priority flag to --install
2025-01-16 22:04:35 +01:00
Andy Hamon
3716ded8df nix-env: add a --priority flag to --install
nix-env can read priorities from a derivations meta attributes, but this
only works when installing a nix expression.

nix-env can also install bare store paths, however meta attributes are
not readable in that case. This means that a store path can not be
installed with a specific priority.

Some cases where it is advantageous to install a store path: a remote
host following a `nix copy`, or any time you want to save some
evaluation time and happen to already know the store path.

This PR addresses this shortcoming by adding a --priority flag to
nix-env --install.
2025-01-16 11:46:25 -08:00
Eelco Dolstra
db46d40b12 Update release note 2025-01-16 13:15:20 +01:00
Eelco Dolstra
6cc5b48a29 Add release note 2025-01-14 14:51:49 +01:00
Domagoj Mišković
5230d3ecc4
Document --max-freed for nix-collect-garbage (#12155)
* Update nix-collect-garbage.md

Referencing issue at: https://github.com/NixOS/nix/issues/12132

Copied the description of `--max-freed` option from 442a2623e4/doc/manual/source/command-ref/nix-store/gc.md (L39-L44)
2025-01-08 14:20:44 +01:00
Domagoj Mišković
3a5fccc418
outdated building instructions, update documentation.md
The current instructions for building the Nix manual include a command that doesn't work as described. Specifically:

```
nix build .#nix^doc
```

Running this command results in the error:

```
error: derivation '/nix/store/hddqxzfqgx2fhj8q66ss3idym7pk7aj1-nix-2.26.0pre20250107_383ab87.drv' does not have wanted outputs 'doc'
```

However, this command works if you specify the Nix version explicitly, such as:

```
nix build nix/2.24.11#nix^doc
```

Additionally, these commands are run within the Nix root directory. 

However, the nix build .#nix^doc command does work when run from the nixpkgs directory and generates the NixOS manual.

I'm not sure if I'm missing something. Is the `nix^doc` supposed to be added somehow to flake outputs?

The incremental build section does not work since as make has been decommissioned in favor of Meson. Should this be simply deleted?
2025-01-08 09:42:26 +01:00
Robert Hensing
91e91f62fa doc: Document nix-store --add-fixed symlink behavior
Tested with

    nix run nix/2.3-maintenance#nix-store -- --add some_symlink
    nix run nix/2.3-maintenance#nix-store -- --add-fixed sha256 --recursive some_symlink
2025-01-07 05:42:03 +00:00