Template to initalize a flake with only the cowsay
and hello
packages. This improves upon the one generated by nix flake init
by being compatible with all available architectures.
- In the directory of your project, run:
nix flake init --template github:jordan-bravo/nix-flake-template
- Edit
flake.nix
and replacecowsay
andhello
with your desired packages. Separate multiple package names with spaces or new lines.
A good way to search for packages is https://search.nixos.org
The shellHook
section is for any shell commands or variables to be set when the development shell starts.
- Run the command:
nix develop
and it will run a shell with the specified packages available and shell variables populated.
Run exit
to leave the development shell.