mirror of
https://github.com/NixOS/nix.git
synced 2024-11-22 06:42:28 +00:00
Compile hand-written release notes with changelog-d
This commit is contained in:
parent
8a52325d7d
commit
b7982372d2
1
.gitignore
vendored
1
.gitignore
vendored
@ -27,6 +27,7 @@ perl/Makefile.config
|
|||||||
/doc/manual/src/contributing/experimental-feature-descriptions.md
|
/doc/manual/src/contributing/experimental-feature-descriptions.md
|
||||||
/doc/manual/src/language/builtins.md
|
/doc/manual/src/language/builtins.md
|
||||||
/doc/manual/src/language/builtin-constants.md
|
/doc/manual/src/language/builtin-constants.md
|
||||||
|
/doc/manual/src/release-notes/rl-next.md
|
||||||
|
|
||||||
# /scripts/
|
# /scripts/
|
||||||
/scripts/nix-profile.sh
|
/scripts/nix-profile.sh
|
||||||
|
@ -144,6 +144,9 @@ $(d)/language.json: $(bindir)/nix
|
|||||||
$(trace-gen) $(dummy-env) $(bindir)/nix __dump-language > $@.tmp
|
$(trace-gen) $(dummy-env) $(bindir)/nix __dump-language > $@.tmp
|
||||||
@mv $@.tmp $@
|
@mv $@.tmp $@
|
||||||
|
|
||||||
|
$(d)/src/release-notes/rl-next.md: $(d)/rl-next/*
|
||||||
|
$(trace-gen) changelog-d doc/manual/rl-next > $@
|
||||||
|
|
||||||
# Generate the HTML manual.
|
# Generate the HTML manual.
|
||||||
.PHONY: manual-html
|
.PHONY: manual-html
|
||||||
manual-html: $(docdir)/manual/index.html
|
manual-html: $(docdir)/manual/index.html
|
||||||
@ -177,7 +180,7 @@ doc/manual/generated/man1/nix3-manpages: $(d)/src/command-ref/new-cli
|
|||||||
# `@docroot@` is to be preserved for documenting the mechanism
|
# `@docroot@` is to be preserved for documenting the mechanism
|
||||||
# FIXME: maybe contributing guides should live right next to the code
|
# FIXME: maybe contributing guides should live right next to the code
|
||||||
# instead of in the manual
|
# instead of in the manual
|
||||||
$(docdir)/manual/index.html: $(MANUAL_SRCS) $(d)/book.toml $(d)/anchors.jq $(d)/custom.css $(d)/src/SUMMARY.md $(d)/src/command-ref/new-cli $(d)/src/contributing/experimental-feature-descriptions.md $(d)/src/command-ref/conf-file.md $(d)/src/language/builtins.md $(d)/src/language/builtin-constants.md
|
$(docdir)/manual/index.html: $(MANUAL_SRCS) $(d)/book.toml $(d)/anchors.jq $(d)/custom.css $(d)/src/SUMMARY.md $(d)/src/command-ref/new-cli $(d)/src/contributing/experimental-feature-descriptions.md $(d)/src/command-ref/conf-file.md $(d)/src/language/builtins.md $(d)/src/language/builtin-constants.md $(d)/src/release-notes/rl-next.md
|
||||||
$(trace-gen) \
|
$(trace-gen) \
|
||||||
tmp="$$(mktemp -d)"; \
|
tmp="$$(mktemp -d)"; \
|
||||||
cp -r doc/manual "$$tmp"; \
|
cp -r doc/manual "$$tmp"; \
|
||||||
|
2
doc/manual/rl-next/config
Normal file
2
doc/manual/rl-next/config
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
organization: NixOS
|
||||||
|
repository: nix
|
@ -220,3 +220,41 @@ Configure your editor to use the `clangd` from the shell, either by running it i
|
|||||||
> For some editors (e.g. Visual Studio Code), you may need to install a [special extension](https://open-vsx.org/extension/llvm-vs-code-extensions/vscode-clangd) for the editor to interact with `clangd`.
|
> For some editors (e.g. Visual Studio Code), you may need to install a [special extension](https://open-vsx.org/extension/llvm-vs-code-extensions/vscode-clangd) for the editor to interact with `clangd`.
|
||||||
> Some other editors (e.g. Emacs, Vim) need a plugin to support LSP servers in general (e.g. [lsp-mode](https://github.com/emacs-lsp/lsp-mode) for Emacs and [vim-lsp](https://github.com/prabirshrestha/vim-lsp) for vim).
|
> Some other editors (e.g. Emacs, Vim) need a plugin to support LSP servers in general (e.g. [lsp-mode](https://github.com/emacs-lsp/lsp-mode) for Emacs and [vim-lsp](https://github.com/prabirshrestha/vim-lsp) for vim).
|
||||||
> Editor-specific setup is typically opinionated, so we will not cover it here in more detail.
|
> Editor-specific setup is typically opinionated, so we will not cover it here in more detail.
|
||||||
|
|
||||||
|
## Add a release note
|
||||||
|
|
||||||
|
`doc/manual/rl-next` contains release notes entries for all unreleased changes.
|
||||||
|
|
||||||
|
User-visible changes should come with a release note.
|
||||||
|
|
||||||
|
### Add an entry
|
||||||
|
|
||||||
|
Here's what a complete entry looks like. The file name is not incorporated in the document.
|
||||||
|
|
||||||
|
```
|
||||||
|
synopsis: Basically a title
|
||||||
|
issues: #1234
|
||||||
|
prs: #1238
|
||||||
|
description: {
|
||||||
|
|
||||||
|
Here's one or more paragraphs that describe the change.
|
||||||
|
|
||||||
|
- It's markdown
|
||||||
|
- Add references to the manual using @docroot@
|
||||||
|
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
Significant changes should add the following header, which moves them to the top.
|
||||||
|
|
||||||
|
```
|
||||||
|
significance: significant
|
||||||
|
```
|
||||||
|
|
||||||
|
<!-- Keep an eye on https://codeberg.org/fgaz/changelog-d/issues/1 -->
|
||||||
|
See also the [format documentation](https://github.com/haskell/cabal/blob/master/CONTRIBUTING.md#changelog).
|
||||||
|
|
||||||
|
### Build process
|
||||||
|
|
||||||
|
Releases have a precomputed `rl-MAJOR.MINOR.md`, and no `rl-next.md`.
|
||||||
|
Non-releases build the release notes on the fly.
|
||||||
|
11
flake.nix
11
flake.nix
@ -173,6 +173,10 @@
|
|||||||
"--enable-internal-api-docs"
|
"--enable-internal-api-docs"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# TODO: after backport of https://github.com/NixOS/nixpkgs/pull/268487, remove `haskellPackages.` -
|
||||||
|
# vastly improves output closure, and adds shell completions
|
||||||
|
changelog-d = pkgs.buildPackages.haskellPackages.changelog-d;
|
||||||
|
|
||||||
nativeBuildDeps =
|
nativeBuildDeps =
|
||||||
[
|
[
|
||||||
buildPackages.bison
|
buildPackages.bison
|
||||||
@ -190,7 +194,10 @@
|
|||||||
buildPackages.jq # Also for custom mdBook preprocessor.
|
buildPackages.jq # Also for custom mdBook preprocessor.
|
||||||
buildPackages.openssh # only needed for tests (ssh-keygen)
|
buildPackages.openssh # only needed for tests (ssh-keygen)
|
||||||
]
|
]
|
||||||
++ lib.optionals stdenv.hostPlatform.isLinux [(buildPackages.util-linuxMinimal or buildPackages.utillinuxMinimal)];
|
++ lib.optionals stdenv.hostPlatform.isLinux [(buildPackages.util-linuxMinimal or buildPackages.utillinuxMinimal)]
|
||||||
|
# Official releases don't have rl-next, so we don't need to compile a changelog
|
||||||
|
++ lib.optional (!officialRelease) changelog-d
|
||||||
|
;
|
||||||
|
|
||||||
buildDeps =
|
buildDeps =
|
||||||
[ curl
|
[ curl
|
||||||
@ -727,6 +734,8 @@
|
|||||||
++ lib.optional
|
++ lib.optional
|
||||||
(stdenv.cc.isClang && stdenv.hostPlatform == stdenv.buildPlatform)
|
(stdenv.cc.isClang && stdenv.hostPlatform == stdenv.buildPlatform)
|
||||||
pkgs.buildPackages.clang-tools
|
pkgs.buildPackages.clang-tools
|
||||||
|
# We want changelog-d in the shell even if it's an official release
|
||||||
|
++ lib.optional officialRelease changelog-d
|
||||||
;
|
;
|
||||||
|
|
||||||
buildInputs = buildDeps ++ propagatedDeps
|
buildInputs = buildDeps ++ propagatedDeps
|
||||||
|
Loading…
Reference in New Issue
Block a user