mirror of
https://github.com/NixOS/nixos-hardware
synced 2024-11-23 03:19:42 +01:00
Create lenovo-yoga-7-14ARH7-amdgpu and lenovo-yoga-7-14ARH7-nvidia entries
- Previous attr-set style providing "amdgpu" and "nvidia" is broken by PR #1046 - Add deprecation assertion for lenovo-yoga-7-14ARH7
This commit is contained in:
parent
0550809b07
commit
5bd0371d3f
3 changed files with 25 additions and 12 deletions
|
@ -212,6 +212,8 @@
|
|||
lenovo-thinkpad-z13-gen2 = import ./lenovo/thinkpad/z/gen2/z13;
|
||||
lenovo-yoga-6-13ALC6 = import ./lenovo/yoga/6/13ALC6;
|
||||
lenovo-yoga-7-14ARH7 = import ./lenovo/yoga/7/14ARH7;
|
||||
lenovo-yoga-7-14ARH7-amdgpu = import ./lenovo/yoga/7/14ARH7/amdgpu;
|
||||
lenovo-yoga-7-14ARH7-nvidia = import ./lenovo/yoga/7/14ARH7/nvidia;
|
||||
lenovo-yoga-7-slim-gen8 = import ./lenovo/yoga/7/slim/gen8;
|
||||
letsnote-cf-lx4 = import ./panasonic/letsnote/cf-lx4;
|
||||
microchip-icicle-kit = import ./microchip/icicle-kit;
|
||||
|
|
16
lenovo/yoga/7/14ARH7/ATTR-SET-DEPRECATION.md
Normal file
16
lenovo/yoga/7/14ARH7/ATTR-SET-DEPRECATION.md
Normal file
|
@ -0,0 +1,16 @@
|
|||
# Deprecation of //lenovo/yoga/7/14ARH7/default.nix
|
||||
|
||||
Background:
|
||||
The `lenovo-yoga-7-14ARH7` provides an attr-set with `amdgpu` and `nvidia` entries, to allow users
|
||||
to choose whether to enable only the AMD-GPU driver, or also enable the NVidia driver with (by
|
||||
default) Prime enabled.
|
||||
|
||||
However, this attr-set style seems to be broken by [PR #1046](https://github.com/NixOS/nixos-hardware/pull/1046),
|
||||
which exports modules as paths, instead.
|
||||
That change seems to cause an error of "value is a path while a set was expected".
|
||||
|
||||
[PR #1053](https://github.com/NixOS/nixos-hardware/pull/1053):
|
||||
- Replaced `lenovo-yoga-7-14ARH7.amdgpu` with a `lenovo-yoga-7-14ARH7-amdgpu` entry.
|
||||
- Replaced `lenovo-yoga-7-14ARH7.nvidia` with a `lenovo-yoga-7-14ARH7-nvidia` entry.
|
||||
- Made `lenovo-yoga-7-14ARH7` throw a deprecation error.
|
||||
- [FIXES: #1052](https://github.com/NixOS/nixos-hardware/issues/1052)
|
|
@ -1,15 +1,10 @@
|
|||
# When using from a Flake, you can access these via imports of the attr key, e.g:
|
||||
#
|
||||
# imports = [
|
||||
# nixos-hardware.nixosModules.lenovo-yoga-7-14ARH7.amdgpu
|
||||
# ];
|
||||
#
|
||||
## or:
|
||||
# imports = [
|
||||
# nixos-hardware.nixosModules.lenovo-yoga-7-14ARH7.nvidia
|
||||
# ];
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
amdgpu = import ./amdgpu;
|
||||
nvidia = import ./nvidia;
|
||||
assertions = [
|
||||
{
|
||||
assertion = false;
|
||||
message = "Importing lenovo/yoga/7/14ARH7/ (default.nix) directly is deprecated! See https://github.com/NixOS/nixos-hardware/blob/master/lenovo/yoga/7/14ARH7/ATTR-SET-DEPRECATION.md for more details";
|
||||
}
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue