~dermetfan/home-manager-shell

41c89b6ad77b5863ff85b46af06c56c7acb1f0df — Robin Stumm 8 months ago 768bb2d
edit README
1 files changed, 15 insertions(+), 14 deletions(-)

M README.md
M README.md => README.md +15 -14
@@ 9,24 9,11 @@ Builds your profile, sets its env vars and `$PATH` to its `/bin`, and bind-mount
If the target flake provides a module in the `homeManagerProfiles.$USER` output it will be imported (unless `-b` is given).

Otherwise use `-i` to add custom imports. `self`, `config`, `lib`, and `pkgs` are available in its scope.
Quickly enable programs using `-e` which is a shortcut for `-i '{ programs.$PROGRAM.enable = true; }'`.

Using `-U` and `-H` you can set username and home directory to adapt the build to your current machine.
If not given, these default to the values of your current `USER` and `HOME` environment variables.

### Examples

Use your home-manager profile on a friend's machine without installing it:

	nix run sourcehut:~dermetfan/home-manager-shell -- -U my_user github:your/flake

Try a friend's home-manager profile without installing it:

	nix run sourcehut:~dermetfan/home-manager-shell github:friends/flake

Run in a temporary home directory ([library](#library) usage assumed for shorter example):

	nix run github:your/flake#app -- -H /tmp/test-home

### Standalone

You can run against any arbitrary flake:


@@ 45,3 32,17 @@ Once you added such an app to your flake you can run it like this:
### CLI Options

See [cli.txt](cli.txt).

### Examples

Use your home-manager profile on a friend's machine without installing it:

	nix run sourcehut:~dermetfan/home-manager-shell -- -U my_user github:your/flake

Try a friend's home-manager profile without installing it:

	nix run sourcehut:~dermetfan/home-manager-shell github:friends/flake

Run in a temporary home directory ([library](#library) usage assumed for shorter example):

	nix run github:your/flake#app -- -H /tmp/test-home