Skip to content

Commit

Permalink
add update instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
fricklerhandwerk committed Nov 2, 2023
1 parent 6c18a10 commit 4293a99
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
17 changes: 17 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,23 @@ Adapted from the [Contributor Covenant] and [The Carpentries Code of Conduct]:
[Contributor Covenant]: https://github.com/EthicalSource/contributor_covenant/blob/cd7fcf684249786b7f7d47ba49c23a6bcb3233eb/content/version/2/1/code_of_conduct.md
[The Carpentries Code of Conduct]: https://github.com/carpentries/docs.carpentries.org/blob/4691971d9f49544054410334140a4fd391a738da/topic_folders/policies/code-of-conduct.md

## Updating reference manuals

With the current setup, the Nix manual hosted on nix.dev does not get updated automatically with new releases.
The following manual steps are required:

- Update the inputs to use the latest versions of the Nix release branches with `nix flake lock`
- Make sure Nix can be fetched from the cache, otherwise it has to be rebuild.
If it doesn't, find the latest commit that is [built by Hydra](https://hydra.nixos.org/project/nix).
- On each new Nix release, update the latest version in [`flake.nix`](./flake.nix) and [`source/reference/nix-manual.md`](./source/reference/nix-manual.md).
- If Nixpkgs unstable or a NixOS stable release adopt a new version of Nix, update the corresponding references here.

Also update URLs to the the Nix manual to the version used by Nixpkgs unstable.
For example, if one wants to move from 2.18 to 2.19:
```bash
sed -i 's#https://nix.dev/manual/nix/2.18/#https://nix.dev/manual/nix/2.19/#g' $(ls **/*.md)
```

## What you can do

### You want to learn and use Nix?
Expand Down
2 changes: 2 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
inputs.flake-utils.url = "github:numtide/flake-utils";
# Various versions of the Nix manuals, see [](nix-manual)
# This requires human interaction to update, especially on new NixOS releases, see ./CONTRIBUTING.md
inputs.nix_2-13.url = "github:NixOS/nix/2.13-maintenance";
inputs.nix_2-17.url = "github:NixOS/nix/2.17-maintenance";
# FIXME: the tip of the branch fails to build on Hydra, but we need it cached
Expand Down

0 comments on commit 4293a99

Please sign in to comment.