Skip to content

Commit

Permalink
update README to include information on how to modify buildFHSUserEnv…
Browse files Browse the repository at this point in the history
… environments
  • Loading branch information
tapdo-staffa committed Mar 25, 2024
1 parent 8176e01 commit e896f8a
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,23 @@ in (phoronix.overrideAttrs (old: {
}))
```

To provide additional packages to buildFHSUserEnv-based environments you can use the `extraPkgs` attribute and `import`
the shell file directly:

```nix
{pkgs ? import <nixpkgs> {}}:
let
yoctoEnv = ((builtins.fetchTarball {
url = "https://github.com/nix-community/nix-environments/archive/master.tar.gz";
})
+ "/envs/yocto/shell.nix");
in
(import yoctoEnv) {
inherit pkgs;
extraPkgs = [pkgs.hello];
}
```

### Nix Flakes

Nix-environments are also available as Flake outputs. Flakes are an [experimental new way to handle Nix expressions](https://nixos.wiki/wiki/Flakes).
Expand Down

0 comments on commit e896f8a

Please sign in to comment.