Merge pull request #123898 from edolstra/revert-nix-experimental
Revert nixExperimental / nixFlakes changes and deprecate nixFlakes attribute
This commit is contained in:
commit
7a2a68316e
|
@ -1,4 +1,4 @@
|
|||
{ fetchFromGitHub, nixStable, callPackage, nixFlakes, nixosTests }:
|
||||
{ fetchFromGitHub, nixStable, callPackage, nixUnstable, nixosTests }:
|
||||
|
||||
{
|
||||
hydra-unstable = callPackage ./common.nix {
|
||||
|
@ -9,7 +9,7 @@
|
|||
rev = "886e6f85e45a1f757e9b77d2a9e4539fbde29468";
|
||||
sha256 = "t7Qb57Xjc0Ou+VDGC1N5u9AmeODW6MVOwKSrYRJq5f0=";
|
||||
};
|
||||
nix = nixFlakes;
|
||||
nix = nixUnstable;
|
||||
|
||||
tests = {
|
||||
basic = nixosTests.hydra.hydra-unstable;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ lib, stdenv, fetchFromGitHub, gnugrep, nixFlakes }:
|
||||
{ lib, stdenv, fetchFromGitHub, gnugrep, nixUnstable }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "nix-direnv";
|
||||
|
@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
|
|||
# Substitute instead of wrapping because the resulting file is
|
||||
# getting sourced, not executed:
|
||||
postPatch = ''
|
||||
sed -i "1a NIX_BIN_PREFIX=${nixFlakes}/bin/" direnvrc
|
||||
sed -i "1a NIX_BIN_PREFIX=${nixUnstable}/bin/" direnvrc
|
||||
substituteInPlace direnvrc --replace "grep" "${gnugrep}/bin/grep"
|
||||
'';
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{ lib
|
||||
, buildPythonApplication
|
||||
, fetchFromGitHub
|
||||
, nixFlakes
|
||||
, nixUnstable
|
||||
, nix-prefetch
|
||||
, nixpkgs-fmt
|
||||
, nixpkgs-review
|
||||
|
@ -19,7 +19,7 @@ buildPythonApplication rec {
|
|||
};
|
||||
|
||||
makeWrapperArgs = [
|
||||
"--prefix" "PATH" ":" (lib.makeBinPath [ nixFlakes nix-prefetch nixpkgs-fmt nixpkgs-review ])
|
||||
"--prefix" "PATH" ":" (lib.makeBinPath [ nixUnstable nix-prefetch nixpkgs-fmt nixpkgs-review ])
|
||||
];
|
||||
|
||||
checkPhase = ''
|
||||
|
|
|
@ -227,12 +227,4 @@ in rec {
|
|||
];
|
||||
});
|
||||
|
||||
nixExperimental = nixUnstable.overrideAttrs (prev: {
|
||||
patches = (prev.patches or []) ++ [ ./enable-all-experimental.patch ];
|
||||
});
|
||||
|
||||
nixFlakes = nixUnstable.overrideAttrs (prev: {
|
||||
patches = (prev.patches or []) ++ [ ./enable-flakes.patch ];
|
||||
});
|
||||
|
||||
}
|
||||
|
|
|
@ -1,14 +0,0 @@
|
|||
diff --git a/src/libstore/globals.cc b/src/libstore/globals.cc
|
||||
index d3b27d7be..e7d002e1d 100644
|
||||
--- a/src/libstore/globals.cc
|
||||
+++ b/src/libstore/globals.cc
|
||||
@@ -172,8 +172,7 @@ MissingExperimentalFeature::MissingExperimentalFeature(std::string feature)
|
||||
|
||||
void Settings::requireExperimentalFeature(const std::string & name)
|
||||
{
|
||||
- if (!isExperimentalFeatureEnabled(name))
|
||||
- throw MissingExperimentalFeature(name);
|
||||
+ return;
|
||||
}
|
||||
|
||||
bool Settings::isWSL1()
|
|
@ -1,14 +0,0 @@
|
|||
diff --git a/src/libstore/globals.hh b/src/libstore/globals.hh
|
||||
index 3e4ead76c..81d407236 100644
|
||||
--- a/src/libstore/globals.hh
|
||||
+++ b/src/libstore/globals.hh
|
||||
@@ -923,7 +923,8 @@ public:
|
||||
value.
|
||||
)"};
|
||||
|
||||
- Setting<Strings> experimentalFeatures{this, {}, "experimental-features",
|
||||
+ Setting<Strings> experimentalFeatures{
|
||||
+ this, {"flakes", "nix-command"}, "experimental-features",
|
||||
"Experimental Nix features to enable."};
|
||||
|
||||
bool isExperimentalFeatureEnabled(const std::string & name);
|
|
@ -1,7 +1,7 @@
|
|||
{ lib
|
||||
, python3
|
||||
, fetchFromGitHub
|
||||
, nixFlakes
|
||||
, nixUnstable
|
||||
, git
|
||||
}:
|
||||
|
||||
|
@ -17,7 +17,7 @@ python3.pkgs.buildPythonApplication rec {
|
|||
};
|
||||
|
||||
makeWrapperArgs = [
|
||||
"--prefix" "PATH" ":" (lib.makeBinPath [ nixFlakes git ])
|
||||
"--prefix" "PATH" ":" (lib.makeBinPath [ nixUnstable git ])
|
||||
];
|
||||
|
||||
doCheck = false;
|
||||
|
|
|
@ -492,6 +492,7 @@ mapAliases ({
|
|||
nginxUnstable = nginxMainline; # added 2018-04-25
|
||||
nilfs_utils = nilfs-utils; # added 2018-04-25
|
||||
nix-review = nixpkgs-review; # added 2019-12-22
|
||||
nixFlakes = nixUnstable; # added 2021-05-21
|
||||
nmap_graphical = nmap-graphical; # added 2017-01-19
|
||||
nologin = shadow; # added 2018-04-25
|
||||
nxproxy = nx-libs; # added 2019-02-15
|
||||
|
|
|
@ -30321,9 +30321,7 @@ in
|
|||
})
|
||||
nix
|
||||
nixStable
|
||||
nixUnstable
|
||||
nixFlakes
|
||||
nixExperimental;
|
||||
nixUnstable;
|
||||
|
||||
nixStatic = pkgsStatic.nix;
|
||||
|
||||
|
|
Loading…
Reference in a new issue