Merge pull request #69746 from Infinisil/rem-opt-usage-message
lib.mkRemovedOptionModule: Show replacement for option usage too
This commit is contained in:
commit
2b1e2f2e97
@ -591,6 +591,7 @@ rec {
|
|||||||
{ options, ... }:
|
{ options, ... }:
|
||||||
{ options = setAttrByPath optionName (mkOption {
|
{ options = setAttrByPath optionName (mkOption {
|
||||||
visible = false;
|
visible = false;
|
||||||
|
apply = x: throw "The option `${showOption optionName}' can no longer be used since it's been removed. ${replacementInstructions}";
|
||||||
});
|
});
|
||||||
config.assertions =
|
config.assertions =
|
||||||
let opt = getAttrFromPath optionName options; in [{
|
let opt = getAttrFromPath optionName options; in [{
|
||||||
|
Loading…
Reference in New Issue
Block a user