nix3-repl
starts interactive Nix shell
TLDR
SYNOPSIS
nix repl [options] [installables...]
DESCRIPTION
nix3-repl is the manual page for nix repl, an interactive read-eval-print loop for Nix expressions. Given files or flakes, it adds their attributes to the lexical scope, which makes it convenient for exploring nixpkgs, NixOS configurations and flake outputs. Tab completion and history are available.
PARAMETERS
INSTALLABLES
Flakes, or attribute paths with --file/--expr, whose attributes are added to the scope.-f, --file FILE
Load attributes from the Nix expression in FILE.--expr EXPR
Load attributes from the expression EXPR.--stdin
Read installables from standard input.--impure
Allow impure evaluation.--help
Display help information.
REPL COMMANDS
:?
Show all special commands.:l file, :lf flake
Load a Nix file or a flake into scope.:r
Reload all loaded files.:b expr
Build a derivation.:p expr
Evaluate and print the result recursively.:e expr
Open a package or function in the editor.:t expr
Describe the type of the result.:doc expr
Show documentation of a builtin function.:log expr
Show the build log of a derivation.:q
Quit.
INSTALL
CAVEATS
There is no nix3 executable: the new-CLI man pages are named nix3-subcommand. Use man nix3-repl or nix repl --help.Requires the nix-command experimental feature (and flakes to load flakes). Older Nix versions loaded a positional path like '<nixpkgs>' as a file; current versions treat positional arguments as installables, so use -f.
HISTORY
nix repl replaced the separate nix-repl tool when it was merged into Nix 2.0 (2018). The repl-flake feature that made positional arguments flakes was folded into flakes in Nix 2.19.
