Commit Graph

2266 Commits

Author SHA1 Message Date
Jörg Thalheim
c0491d5fd2
Merge pull request #204343 from urandom2/sridoc
doc: use sri hash syntax
2022-12-04 10:04:57 +01:00
Colin Arnott
bac379f30a
doc: use sri hash syntax
The nixpkgs manual contains references to both sri hash and explicit
sha256 attributes. This is at best confusing to new users. Since the
final destination is exclusive use of sri hashes, see nixos/rfcs#131,
might as well push new users in that direction gently.

Notable exceptions to sri hash support are builtins.fetchTarball,
cataclysm-dda, coq, dockerTools.pullimage, elixir.override, and
fetchCrate. None, other than builtins.fetchTarball, are fundamentally
incompatible, but all currently accept explicit sha256 attributes as
input. Because adding backwards compatibility is out of scope for this
change, they have been left intact, but migration to sri format has been
made for any using old hash formats.

All hashes have been manually tested to be accurate, and updates were
only made for missing upstream artefacts or bugs.
2022-12-04 06:12:18 +00:00
figsoda
75c01e730d
Merge pull request #203520 from figsoda/nextest
rustPlatform.buildRustPackage: add cargo-nextest support
2022-12-03 19:03:34 -05:00
Arnout Engelen
cfdd900d66
manual: update meta-attributes section
Promote the `maintainers = with maintainers; [ ]` syntax as that is most common
in nixpkgs, and remove the `nix-env` example which doesn't work like that anymore.
2022-12-03 10:04:15 +00:00
Victor Engmark
9cf0ee43e7 doc: Use POSIX syntax to source file
Avoids bashism in case another shell is active.
2022-11-29 08:39:37 -05:00
Victor Engmark
22d3b5a9e9 doc: Quote variable references 2022-11-29 08:39:37 -05:00
Victor Engmark
852ef6e971 doc: Fix grammar 2022-11-29 08:39:37 -05:00
figsoda
0f386d1896 docs/rust: document cargoNextestHook and useNextest 2022-11-28 18:30:30 -05:00
Silvan Mosberger
a566d0842e
Merge pull request #172736 from infinisil/docker-nix-shell 2022-11-26 20:21:59 +01:00
Winter
125bd1f0b5 doc/languages-frameworks/javascript: update deps hash in example 2022-11-23 20:52:08 -05:00
figsoda
82fe76d1cd carnix,cratesIO: remove 2022-11-22 14:10:25 -05:00
Winter
93334f5234 npmHooks.npmInstallHook: pass install flags to prune 2022-11-21 15:00:08 -05:00
Sandro
3a05360e53
Merge pull request #200082 from panicgh/fetchgit-sparse-checkout 2022-11-21 20:00:56 +01:00
Artturi
80212614a3
Merge pull request #187921 from amjoseph-nixpkgs/pr/manual/rust/buildRustY
doc/../rust.section.md: prominently mention `buildRustXX` names
2022-11-21 19:08:38 +02:00
Robert Hensing
29352751cf
Merge pull request #196251 from hercules-ci/testers-build-failure-and-equal-contents
`testers`: Add `testBuildFailure` and `testEqualContents`
2022-11-21 06:17:00 +01:00
Martin Weinelt
18ab6d062b
sphinxHook: inherit from python3Packages 2022-11-20 15:39:34 +01:00
Artturin
341e6fd558 splice.nix: start deprecating nativeDrv and crossDrv 2022-11-19 00:04:54 +02:00
Nicolas Benes
f6b07f0e2f fetchgit: make sparseCheckout a list of strings
The `sparseCheckout` argument allows the user to specify directories or
patterns of files, which Git uses to filter files it should check-out.

Git expects a multi-line string on stdin ("newline-delimited list", see
`git-sparse-checkout(1)`), but within nixpkgs it is more consistent to
use a list of strings instead. The list elements are joined to a
multi-line string only before passing it to the builder script.

A deprecation warning is emitted if a (multi-line) string is passed to
`sparseCheckout`, but for the time being it is still accepted.
2022-11-15 19:45:33 +01:00
Jocelyn Thode
2f933d60fb doc/vim: Clarify buildVimPlugin/buildVimPluginFrom2Nix 2022-11-14 14:59:13 -05:00
John Ericson
cd27a5b436
Merge pull request #82131 from Ericson2314/bsd-cross
FreeBSD packages: Init at 13.1
2022-11-13 21:35:17 -05:00
github-actions[bot]
f3a93620b1
Merge master into staging-next 2022-11-10 12:01:27 +00:00
Shamrock Lee
da31bd5673 patchRcPathBash, patchRcPathCsh, patchRcPathFish, patchRcPathPosix: init
Init patchRcPath hooks, which provides
utilities to patch shell scripts to be sourced by users.

Add test cases and documentation.
2022-11-10 09:23:52 +08:00
github-actions[bot]
d99020653d
Merge master into staging-next 2022-11-09 18:01:11 +00:00
Winter
16722903aa buildNpmPackage: init 2022-11-09 10:35:59 -05:00
github-actions[bot]
81316207ec
Merge master into staging-next 2022-11-09 00:02:55 +00:00
github-actions[bot]
4517d658d3
Merge master into staging-next 2022-11-08 18:01:16 +00:00
Ryan Mulligan
f3d0e1d5c3 nixpkgs/doc: fix admonition syntax
Match admonition syntax in

https://nixos.org/manual/nixpkgs/unstable/#chap-contributing
2022-11-08 07:30:20 -08:00
Ryan Mulligan
962a810513 nixpkgs/doc/stdenv: fix admonition class
Change to match the formatting of the other admonitions that use
classes.

This was breaking the mmdoc output.
2022-11-07 13:32:21 -08:00
github-actions[bot]
a9864a3f5a
Merge master into staging-next 2022-11-06 06:01:30 +00:00
Anderson Torres
4b59590ac5
Revert "lib,doc: remove obvious usages of toString on paths" 2022-11-05 21:57:23 -03:00
github-actions[bot]
a46c8c1b26
Merge master into staging-next 2022-11-06 00:02:47 +00:00
Artturin
66cf79f282 lib,doc: remove obvious usages of toString on paths
It gives a warning on the lazy-trees branch of Nix
(NixOS/nix#6530)

one of these was also giving me an error (the one in lib/trivial probably)

```
$ nix build
warning: applying 'toString' to path '/home/artturin/nixgits/my-nixpkgs/nixos/modules/installer/sd-card/sd
-image-aarch64.nix' and then accessing it is deprecated, at /home/artturin/nixgits/my-nixpkgs/lib/modules.
nix:349:99
warning: applying 'toString' to path '/home/artturin/nixgits/my-nixpkgs/.git' and then accessing it is dep
recated, at /home/artturin/nixgits/my-nixpkgs/lib/sources.nix:35:32
warning: applying 'toString' to path '/home/artturin/nixgits/my-nixpkgs/nixos/modules/system/etc/etc.nix'
and then accessing it is deprecated, at «stdin»:0
warning: applying 'toString' to path '/home/artturin/nixgits/my-nixpkgs/nixos/modules/system/etc/etc-activ
ation.nix' and then accessing it is deprecated, at «stdin»:0
warning: applying 'toString' to path '/home/artturin/nixgits/my-nixpkgs/nixos/modules/installer/sd-card/sd
-image-aarch64.nix' and then accessing it is deprecated, at «stdin»:0
error: cannot decode virtual path '/nix/store/virtual0000000000000000000000005-source'
(use '--show-trace' to show detailed location information)
```
2022-11-06 00:00:39 +02:00
John Ericson
66aa02f190 lib/systems: Support FreeBSD
A tricky thing about FreeBSD is that there is no stable ABI across
versions. That means that putting in the version as part of the config
string is paramount.

We have a parsed represenation that separates name versus version to
accomplish this. We include FreeBSD versions 12 and 13 to demonstrate
how it works.
2022-11-04 16:49:28 -04:00
github-actions[bot]
08b08d0caf
Merge staging-next into staging 2022-11-04 00:03:34 +00:00
Guillaume Girol
3befade691 doc: fix python module override example 2022-11-03 19:54:51 +01:00
github-actions[bot]
a8e550e843
Merge staging-next into staging 2022-11-01 00:03:36 +00:00
0x4A6F
b37df78bfe
doc/languages-frameworks/rust: example for disabling tests (#198705) 2022-10-31 22:39:34 +01:00
github-actions[bot]
85d6819fff
Merge staging-next into staging 2022-10-31 18:03:46 +00:00
figsoda
0426b36f9f doc/vim: update docs for nvim-treesitter 2022-10-31 09:44:02 -04:00
John Ericson
0c09b3d17c
Merge pull request #197937 from danielbarter/cc-wrapper-hook
cc-wrapper: adding a cc-wrapper-hook to the cc-wrapper
2022-10-28 17:30:03 +01:00
Robert Hensing
e20a362908 testers.testEqualContents: init 2022-10-27 14:06:38 +02:00
Robert Hensing
44d0f37833 testers.testBuildFailure: init 2022-10-27 14:06:38 +02:00
Daniel Barter
77bd639c4c cc-wrapper: adding a cc-wrapper-hook to the cc-wrapper 2022-10-26 09:33:43 -07:00
Silvan Mosberger
c0c3c3f1c4
Merge pull request #197905 from infinisil/lib-filesystem-docs
lib: Automatically generate lib.filesytem docs
2022-10-26 18:11:32 +02:00
Silvan Mosberger
9bfc4bbd63 lib: Automatically generate lib.filesytem docs 2022-10-26 15:10:47 +02:00
Jan Tojnar
fa285355ee nixos/doc/manual/md-to-db.sh: Add support for <kbd> element 2022-10-26 01:46:44 +02:00
Emilia Bopp
8bec7996cc doc: fix syntax error in Lua documentation 2022-10-25 22:34:32 +02:00
Stanisław Pitucha
713369c44b doc/contributing: Explicitly allow trivial changes by non-authors
Discussed and proposed at https://discourse.nixos.org/t/rules-around-adding-to-someones-pr/22671/3
2022-10-23 15:23:02 +11:00
Janne Heß
1b768f41e9
Merge pull request #173506 from helsinki-systems/feat/document-no-breaking-commits
doc: Document that the staging branches may be restricted
2022-10-21 22:58:33 +02:00
Robert Hensing
c1311d1223 doc/stdenv: Move Other hooks after all hooks 2022-10-13 21:15:19 +02:00
Robert Hensing
53088569de doc/stdenv: Clarify that the wrappers come with hooks 2022-10-13 21:14:21 +02:00
Robert Hensing
f4c6286284 doc/stdenv: Improve language a bit 2022-10-13 21:14:04 +02:00
Robert Hensing
2db8de920e doc: Move non-stdenv hooks out of stdenv chapter 2022-10-13 15:40:27 +02:00
Robert Hensing
5b055190e3 doc/stdenv: Clarify status of the hooks 2022-10-13 13:36:47 +02:00
Adam Joseph
0d0c03fb0b
coding-conventions.chapter.md: update to account for #89885 (#191378)
https://github.com/NixOS/nixpkgs/pull/89885 ensures that fetches are
done securely (i.e. without `--insecure`) when the `hash` parameter is one of
the four special "fake" hashes.  However the manual was not updated in that PR.
This commit updates the manual to account for the already-merged changes from
that PR.

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-10-12 11:08:50 +02:00
Silvan Mosberger
8ec0837a72 Introduce dockerTools.buildNixShellImage 2022-10-07 22:04:22 +02:00
Дамјан Георгиевски
4e385bec15
add documentation for the pkgs.portableService tool (#193081)
* add documentation for the pkgs.portableService tool

as introduced in 499aebcf34

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-10-07 10:37:56 +02:00
Théo Zimmermann
2dc3552aa1 coqPackages.mkCoqDerivation: upgrade to Dune 3
And remove the version number from the corresponding attributes.
2022-10-02 14:42:28 +02:00
Robert Hensing
7f0d934f9a
Merge pull request #191540 from hercules-ci/nixosTest-modular
nixosTest: make modular
2022-09-28 10:27:45 +01:00
José Romildo
1f239257c5 maintainers/scripts/update.nix: make package name, pname and old version available to the update script 2022-09-26 22:16:19 -03:00
Ivv
2650d450a7
Merge pull request #190403 from IvarWithoutBones/dotnetmodule-fixes
buildDotnetModule: several usability improvements
2022-09-26 15:04:31 +02:00
Robert Hensing
6205d37747 nixos/testing: Improve option docs 2022-09-24 17:38:10 +01:00
Frederik Rietdijk
9e02095f4e Python docs: document attribute to use for non-PyPI projects 2022-09-22 13:31:58 +02:00
Robert Hensing
b2def3c2ce doc/postgresql-test-hook: Add example 2022-09-19 18:14:31 +01:00
Ivar Scholten
8e00d6ac26
buildDotnetModule: move nugetDeps throw to when its actually needed
Previously we had an assert that would complain when nugetDeps wasnt set,
which also didnt allow any passthru attributes (like fetch-deps) to be
build. That causes a cycle where you need nugetDeps to fetch the nuget
deps, but arent able to build the script to do so.
2022-09-18 18:00:37 +02:00
Ivar Scholten
03a1b62cb3
buildDotnetModule: dont require specifing a projectFile
In a lot of cases dotnet can figure this out by itself, so we can just
invoke it without the project argument.
2022-09-18 18:00:37 +02:00
Dennis Gosnell
533e1f0468
Merge pull request #190795 from cdepillabout/coq-add-docs
doc/language-frameworks/coq: add explanation of how to override packages
2022-09-16 09:09:09 -04:00
davidak
63f7b8c945
Merge pull request #190818 from IvarWithoutBones/testversion-doc
doc/testers: testVersion -> testers.testVersion, add example
2022-09-15 23:48:56 +02:00
Ivar Scholten
6c40872147
doc/testers: testVersion -> testers.testVersion, add example 2022-09-15 22:46:37 +02:00
Dennis Gosnell
6cc6850fe2
doc/language-frameworks/coq: add explanation of how to override packages 2022-09-15 09:18:20 -04:00
Matthieu Coudron
800323c0c0 doc(vim): take into account plug non-support
Apply suggestions from code review

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-09-11 20:33:01 +02:00
Matthieu Coudron
3944240476 doc(neovim): remove the mention of plug for neovim
This was removed to simplify configuration. One could create a function that converts the plug format to vim native package format (only plugin system supported for neovim)  and upstream it to nixpkgs if that's an issue
2022-09-11 18:11:16 +02:00
Matthieu Coudron
584bc20aa0 doc: present how to create a vim-plugin overlay
it is possible to maintain an out of tree list of neovim plugins with this method

Update doc/languages-frameworks/vim.section.md

Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
2022-09-11 18:11:16 +02:00
Sandro
1bb33d6dbe
doc/contributing: fix whitespace 2022-09-07 01:01:48 +02:00
Anderson Torres
6be0f0e057
Merge pull request #189241 from SuperSandro2000/git-full-hash
doc/contributing: enforce full commit hashes on github
2022-09-05 21:26:05 -03:00
Sandro Jäckel
be09c1638d
doc/contributing: enforce full commit hashes on github 2022-09-04 00:50:35 +02:00
Ian Macalinao
30a5965216
doc/languages-frameworks/rust: fix typo 2022-09-03 15:45:21 -05:00
Marc Scholten
41de927b70 doc: Clarify default value of sourceRoot 2022-09-03 11:13:58 +02:00
pennae
3bddcf5f90
Merge branch 'master' into option-docs-md 2022-09-01 16:10:09 +02:00
pennae
9c3c13b50d nixos/make-options-doc: add inline roles for varname/envar
both of these render distinctly from plain literals in the manpage, and
manpages even semantically distinguish between the two.
2022-08-31 16:21:10 +02:00
Robert Hensing
62b25a28fe
Merge pull request #170906 from Sohalt/dockerTools.ca-certificates.crt
dockerTools ca-certificates.crt helper
2022-08-31 14:08:02 +02:00
Robert Hensing
507d35c207
Merge pull request #188805 from ncfavier/longDescription-format
doc: specify that `longDescription` should be Markdown
2022-08-30 00:13:02 +02:00
Naïm Favier
2f88279ab9
doc: specify that longDescription should be Markdown
In the spirit of RFC 72, document that longDescription is in CommonMark.
2022-08-29 20:19:34 +02:00
Martin Weinelt
986c31401e
doc/python: Properly sort pythonRelaxDepsHook in hook list 2022-08-24 23:03:31 +02:00
Martin Weinelt
8a26deba06
doc/python: integrate sphinxHook docs
Improve the documentation by moving it from the hook script into the
Python section in the manual and adding code examples.
2022-08-24 23:02:24 +02:00
Adam Joseph
aad7f1d6b3 doc/../rust.section.md: prominently mention buildRustXX names
This was a source of massive confusion for me when I first learned my way around nixpkgs' rust machinery.  I seek to save others from that confusion.

* `buildRustPackage` should have been named `buildRustPackageUsingCargo`

* `buildRustCrate` should have been named `buildRustPackageUsingNix`

It is, unfortunately, too late to fix this.  Let's do the next best thing and make the names `buildRustPackage` and `buildRustCrate` very prominent in the documentation, so readers see immediately that they need to learn the following jargon:

* `buildRustPackage` means "build this Rust crate by calling `cargo` in one (or two) monolithic derivations"

* `buildRustCrate` means "build this Rust crate by calling `rustc` in one derivation for each crate"
2022-08-22 14:37:41 -07:00
github-actions[bot]
318717f2e3
Merge master into staging-next 2022-08-20 00:02:22 +00:00
Valentin Gagarin
16eb45c655 doc: add note about makeWrapper and PATH modification 2022-08-19 13:11:27 -05:00
github-actions[bot]
954d3734e9
Merge master into staging-next 2022-08-17 12:01:28 +00:00
Alex James
c9af898255
dockerTools.buildImage: make VM memSize configurable
Fixes #186752. This adds buildVMMemorySize (defaults to 512 MiB) to
buildImage, which is passed to vm.runInLinuxVM. This is needed for
larger base images, which may otherwise cause container build failures
due to OOM in the VM.
2022-08-16 21:47:29 -05:00
github-actions[bot]
842c52c5ba
Merge staging-next into staging 2022-08-15 00:03:15 +00:00
Winter
dbd18a63a7 fetchgit: allow disabling cone mode for sparse checkouts, fix test 2022-08-14 23:03:07 +02:00
Winter
e8fbb38a51 pythonPackages.unittestCheckHook: init 2022-08-13 14:09:43 -04:00
Frederik Rietdijk
2270b66d75 pythonPackagesExtensions: override all Python package sets at once
Python package sets can be overridden by overriding an interpreter
and passing in `packageOverrides = self: super: {...};`. This is fine
in case you need a single interpreter, however, it does not help you
when you want to override all sets.

With this change it is possible to override all sets at once by
appending a list of "extensions" to `pythonPackagesExtensions`.

From reading the implementation you might wonder why a list is used, and
not
`lib.composeExtensions`? The reason is the latter requires knowledge of
the library function. This approach should be easier for most users
as it is similar to how we append to lists of e.g. inputs or patches
when overriding a derivation.
2022-08-06 09:39:39 +02:00
Florian Klink
00ff154265
Merge pull request #174093 from NixOS/doc-fakenss
nixos/doc: document fakeNss, binSh
2022-08-04 21:06:19 +07:00
Matthias Bartelmeß
0ff5e21ea2
Correct instructions to obtain a hash for git repos 2022-08-04 00:31:31 +02:00
Valentin Gagarin
671ce969a9
Merge pull request #179489 from Thornycrackers-Forks/fetcher-docs-update
doc/builders/fetchers: Add examples, reduce sentence complexity
2022-08-03 11:50:56 +02:00
Valentin Gagarin
163e81aac0
Merge pull request #184848 from jtojnar/mkder-rec-anchor
doc: Add anchor to Recursive attributes in `mkDerivation`
2022-08-03 11:18:36 +02:00
Cody Hiar
3c2cd351d4 Add example error message. 2022-08-02 11:07:36 -06:00
Cody Hiar
9c292dd02e Updating sha256 to more realistic example 2022-08-02 10:55:15 -06:00