diff --git a/README.md b/README.md index 66c2d99..d28eee1 100644 --- a/README.md +++ b/README.md @@ -178,6 +178,35 @@ p2nix.mkPoetryApplication { } ``` +or as a [nixpkgs overlay](https://nixos.org/nixpkgs/manual/#chap-overlays): +```nix +let + pkgs = import { + overlays = [ + # self & super refers to nixpkgs + (self: super: { + + # p2self & p2super refers to poetry2nix + poetry2nix = super.poetry2nix.overrideScope' (p2nixself: p2nixsuper: { + + # pyself & pysuper refers to python packages + defaultPoetryOverrides = p2nixsuper.defaultPoetryOverrides.extend (pyself: pysuper: { + + my-custom-pkg = super.my-custom-pkg.overridePythonAttrs (oldAttrs: { }); + + }); + + }); + }) + + ]; + }; + +in pkgs.poetry2nix.mkPoetryApplication { + projectDir = ./.; +} +``` + ## Contributing Contributions to this project are welcome in the form of GitHub PRs. Please consider the following before creating PRs: