mirror of
https://github.com/NixOS/nix
synced 2025-07-07 01:51:47 +02:00
flakes: adopt repl-flake behavior as default
This commit is contained in:
parent
ea2fa8b6f3
commit
13ed5d7106
5 changed files with 9 additions and 10 deletions
|
@ -163,6 +163,8 @@ constexpr std::array<ExperimentalFeatureDetails, 14> xpFeatureDetails = {{
|
|||
.tag = Xp::ReplFlake,
|
||||
.name = "repl-flake",
|
||||
.description = R"(
|
||||
*Enabled with [`flakes`](#xp-feature-flakes) since 2.19*
|
||||
|
||||
Allow passing [installables](@docroot@/command-ref/new-cli/nix.md#installables) to `nix repl`, making its interface consistent with the other experimental commands.
|
||||
)",
|
||||
},
|
||||
|
|
|
@ -47,7 +47,7 @@ struct CmdRepl : RawInstallablesCommand
|
|||
|
||||
void applyDefaultInstallables(std::vector<std::string> & rawInstallables) override
|
||||
{
|
||||
if (!experimentalFeatureSettings.isEnabled(Xp::ReplFlake) && !(file) && rawInstallables.size() >= 1) {
|
||||
if (!experimentalFeatureSettings.isEnabled(Xp::Flakes) && !(file) && rawInstallables.size() >= 1) {
|
||||
warn("future versions of Nix will require using `--file` to load a file");
|
||||
if (rawInstallables.size() > 1)
|
||||
warn("more than one input file is not currently supported");
|
||||
|
|
|
@ -36,7 +36,7 @@ R""(
|
|||
Loading Installable ''...
|
||||
Added 1 variables.
|
||||
|
||||
# nix repl --extra-experimental-features 'flakes repl-flake' nixpkgs
|
||||
# nix repl --extra-experimental-features 'flakes' nixpkgs
|
||||
Loading Installable 'flake:nixpkgs#'...
|
||||
Added 5 variables.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue