From 99af052d22307360665962a87847273366024b4e Mon Sep 17 00:00:00 2001 From: Michal Sojka Date: Sat, 28 Dec 2024 17:06:30 +0100 Subject: [PATCH] README: Document --patches --- README.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/README.md b/README.md index 26f6cd2..94af0a0 100644 --- a/README.md +++ b/README.md @@ -89,6 +89,21 @@ the [Autoware][] project as an example. > configuration, you may need to add `--experimental-features > 'nix-command flakes'`). +3. If some packages need changes, you can generate Nix expressions + with appropriate patches. Commit the needed changes and run + `ros2nix` with the `--patches` flag, e.g.: + + ```sh + pushd autoware/src/...package... + $EDITOR some-file.cxx + git commit some-file.cxx + popd + ros2nix --output-as-nix-pkg-name --fetch --patches $(find -name package.xml|grep -v ament_cmake) + ``` + + An example of the resulting Nix expression can be seen + [here](https://github.com/wentasah/autoware.nix/blob/68772be6c4c263cfa213921e205f27f68dc4826a/pkgs/autoware-universe-utils.nix#L15-L18). + [Autoware]: https://autoware.org/ ## ros2nix reference