mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-03-22 18:02:45 +00:00
Update cheatsheets
This commit is contained in:
31
tldr/nh
31
tldr/nh
@@ -5,33 +5,30 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# nh
|
||||
|
||||
> Modern helper utility tool for the Nix/Nixos ecosystem.
|
||||
> Modern helper utility tool for the Nix/NixOS ecosystem.
|
||||
> Some subcommands such as `os`, `home`, `clean`, `search` have their own usage documentation.
|
||||
> More information: <https://github.com/nix-community/nh#usage>.
|
||||
|
||||
- Search for a package in Nixpkgs, limiting results:
|
||||
- Build and switch to a specified NixOS flake configuration:
|
||||
|
||||
`nh search {{[-l|--limit]}} {{number}} {{name}}`
|
||||
`nh os switch {{path/to/flake}}`
|
||||
|
||||
- Collect all garbage and gcroots from the Nix store:
|
||||
- Build and switch to a specified Home Manager flake configuration:
|
||||
|
||||
`nh clean all {{[-a|--ask]}}`
|
||||
|
||||
- Build a specified Nixos flake configuration and create a symlink of the result from the Nix store:
|
||||
|
||||
`nh os build-vm {{path/to/flake}} {{[-H|--hostname]}} {{host}}`
|
||||
|
||||
- Build and test a specified Nixos flake configuration:
|
||||
|
||||
`nh os test {{path/to/flake}} {{[-H|--hostname]}} {{nixos}}`
|
||||
|
||||
- Build and switch to a specified Home manager flake configuration:
|
||||
|
||||
`nh home switch {{path/to/flake}} {{[-c|--configuration]}} {{home}}`
|
||||
`nh home switch {{path/to/flake}}`
|
||||
|
||||
- Build and switch to a nix-darwin flake configuration:
|
||||
|
||||
`nh darwin switch {{path/to/flake}} {{[-H|--hostname]}} {{host}}`
|
||||
|
||||
- Collect all garbage and gcroots from the Nix store:
|
||||
|
||||
`nh clean all {{[-a|--ask]}}`
|
||||
|
||||
- Search for a package in Nixpkgs:
|
||||
|
||||
`nh search {{name}}`
|
||||
|
||||
- Generate shell completions for a specified shell:
|
||||
|
||||
`nh completions {{shell}}`
|
||||
|
||||
Reference in New Issue
Block a user