Add Home Manager on others distros
Some checks failed
check / check (push) Failing after 0s

This commit is contained in:
Florian RICHER 2024-10-28 20:14:20 +01:00
parent 9390144b66
commit c99413011e
Signed by: florian.richer
GPG key ID: C73D37CBED7BFC77
2 changed files with 34 additions and 1 deletions

View file

@ -2,4 +2,5 @@
- [Debug insecure package error](./debug_insecure_package.md)
- [How try pull request](./how_to_test_pr.md)
- [Build and run VM from nixos configuration](./test_on_vm.md)
- [Build and run VM from nixos configuration](./test_on_vm.md)
- [Home Manager on others distros](./home_manager.md)

32
tips/home_manager.md Normal file
View file

@ -0,0 +1,32 @@
# Home Manager on others distros
## Install home-manager
1. Add `nixpkgs` and `home-manager` channels
```bash
nix-channel --add https://nixos.org/channels/nixpkgs-unstable
nix-channel --add https://github.com/nix-community/home-manager/archive/master.tar.gz home-manager
nix-channel --update
```
2. Install `home-manager`
```bash
export NIX_PATH=$HOME/.nix-defexpr/channels:/nix/var/nix/profiles/per-user/root/channels${NIX_PATH:+:$NIX_PATH}
nix-shell '<home-manager>' -A install
```
## How use home-manager
1. Switch
```bash
home-manager switch --flake .#perso-home
```
2. List generations
```bash
home-manager generations
```