From 5789cc3754a8b97900d09bca0e3ef29c5879e13b Mon Sep 17 00:00:00 2001 From: Silvan Mosberger Date: Fri, 4 Aug 2023 20:02:54 +0200 Subject: CONTRIBUTING.md: Clean up "Making patches" section Moving and collecting bits into the appropriate places, also writing some new sentences --- pkgs/README.md | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'pkgs/README.md') diff --git a/pkgs/README.md b/pkgs/README.md index 2f511a35c5d74..055c8e76a5c4a 100644 --- a/pkgs/README.md +++ b/pkgs/README.md @@ -544,6 +544,15 @@ This is how the pull request looks like in this case: [https://github.com/NixOS/ ## Testing changes | Package tests {#sec-package-tests} +- update pkg + - `nix-env -iA pkg-attribute-name -f ` +- add pkg + - Make sure it’s in `pkgs/top-level/all-packages.nix` + - `nix-env -iA pkg-attribute-name -f ` +- _If you don’t want to install pkg in you profile_. + - `nix-build -A pkg-attribute-name ` and check results in the folder `result`. It will appear in the same directory where you did `nix-build`. +- If you installed your package with `nix-env`, you can run `nix-env -e pkg-name` where `pkg-name` is as reported by `nix-env -q` to uninstall it from your system. + To run the main types of tests locally: - Run package-internal tests with `nix-build --attr pkgs.PACKAGE.passthru.tests` -- cgit 1.4.1