mirror of
https://github.com/nix-community/nixvim.git
synced 2026-08-24 10:14:03 -05:00
modules/nixpkgs: warn about platform specs
Document that fully elaborated platform attrsets from another Nixpkgs instance can be unsafe when Nixvim imports a different nixpkgs.source.
(cherry picked from commit c6a99bb41f)
This commit is contained in:
committed by
Matt Sturgeon
parent
63c00fb9d6
commit
ee3cfbdeda
@@ -168,6 +168,12 @@ in
|
||||
To cross-compile, also set `nixpkgs.buildPlatform`.
|
||||
|
||||
Ignored when `nixpkgs.pkgs` is set.
|
||||
|
||||
> [!WARNING]
|
||||
> Avoid passing a fully elaborated platform from another Nixpkgs instance,
|
||||
> such as `pkgs.stdenv.hostPlatform`, when `nixpkgs.source` may point to a
|
||||
> different Nixpkgs revision. Prefer a platform spec, such as
|
||||
> `{ inherit (pkgs.stdenv.hostPlatform) config; }`, or a system string.
|
||||
'';
|
||||
};
|
||||
|
||||
@@ -195,6 +201,12 @@ in
|
||||
Setting this option will cause Nixvim to be cross-compiled.
|
||||
|
||||
Ignored when `nixpkgs.pkgs` is set.
|
||||
|
||||
> [!WARNING]
|
||||
> Avoid passing a fully elaborated platform from another Nixpkgs instance,
|
||||
> such as `pkgs.stdenv.buildPlatform`, when `nixpkgs.source` may point to a
|
||||
> different Nixpkgs revision. Prefer a platform spec, such as
|
||||
> `{ inherit (pkgs.stdenv.buildPlatform) config; }`, or a system string.
|
||||
'';
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user