mirror of
https://github.com/Theaninova/TheaninovOS.git
synced 2025-12-12 11:36:20 +00:00
feat: stuff
This commit is contained in:
@@ -49,8 +49,7 @@
|
|||||||
cc1.enable = true;
|
cc1.enable = true;
|
||||||
fv43u.enable = true;
|
fv43u.enable = true;
|
||||||
virtual-camera.enable = true;
|
virtual-camera.enable = true;
|
||||||
# https://github.com/NixOS/nixpkgs/pull/300682
|
hid-fanatecff.enable = true;
|
||||||
# hid-fanatecff.enable = true;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
fonts = {
|
fonts = {
|
||||||
|
|||||||
@@ -83,7 +83,7 @@
|
|||||||
disable_hyprland_logo = true;
|
disable_hyprland_logo = true;
|
||||||
background_color = "0x000000";
|
background_color = "0x000000";
|
||||||
force_default_wallpaper = 0;
|
force_default_wallpaper = 0;
|
||||||
vrr = 1;
|
vrr = 2;
|
||||||
};
|
};
|
||||||
layerrule = [
|
layerrule = [
|
||||||
"blur, anyrun"
|
"blur, anyrun"
|
||||||
|
|||||||
@@ -341,7 +341,7 @@ in
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixd.enable = true;
|
nil_ls.enable = true;
|
||||||
lua-ls.enable = true;
|
lua-ls.enable = true;
|
||||||
bashls.enable = true;
|
bashls.enable = true;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -10,6 +10,7 @@
|
|||||||
./fonts/noto-sans.nix
|
./fonts/noto-sans.nix
|
||||||
./fonts/nerdfonts.nix
|
./fonts/nerdfonts.nix
|
||||||
|
|
||||||
|
./hardware/hid-fanatecff.nix
|
||||||
./hardware/audio.nix
|
./hardware/audio.nix
|
||||||
./hardware/gbmonctl.nix
|
./hardware/gbmonctl.nix
|
||||||
./hardware/nvidia-proprietary.nix
|
./hardware/nvidia-proprietary.nix
|
||||||
|
|||||||
41
modules/nixos/hardware/hid-fanatecff-pkg.nix
Normal file
41
modules/nixos/hardware/hid-fanatecff-pkg.nix
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
{
|
||||||
|
lib,
|
||||||
|
stdenv,
|
||||||
|
kernel,
|
||||||
|
fetchFromGitHub,
|
||||||
|
}:
|
||||||
|
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
|
pname = "hid-fanatecff";
|
||||||
|
version = "0.1.0";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "gotzl";
|
||||||
|
repo = "hid-fanatecff";
|
||||||
|
rev = "0.1";
|
||||||
|
hash = "sha256-1Nm/34Er/qfel9LJp++IWd7cTh2Wi93Kgd28YLMVvWo=";
|
||||||
|
};
|
||||||
|
|
||||||
|
nativeBuildInputs = kernel.moduleBuildDependencies;
|
||||||
|
|
||||||
|
makeFlags = kernel.makeFlags ++ [
|
||||||
|
"KVERSION=${kernel.modDirVersion}"
|
||||||
|
"KERNEL_SRC=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
|
||||||
|
];
|
||||||
|
|
||||||
|
installPhase = ''
|
||||||
|
mkdir -p $out/etc/udev/rules.d
|
||||||
|
cp ${src}/fanatec.rules $out/etc/udev/rules.d/99-fanatec.rules
|
||||||
|
mkdir -p $out/lib/modules/${kernel.modDirVersion}/kernel/drivers/hid
|
||||||
|
cp hid-fanatec.ko $out/lib/modules/${kernel.modDirVersion}/kernel/drivers/hid
|
||||||
|
'';
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Driver to support FANATEC input devices, in particular ForceFeedback of various wheel-bases";
|
||||||
|
homepage = "https://github.com/gotzl/hid-fanatecff";
|
||||||
|
license = licenses.gpl2Only;
|
||||||
|
maintainers = with maintainers; [ theaninova ];
|
||||||
|
platforms = platforms.linux;
|
||||||
|
broken = stdenv.isAarch64;
|
||||||
|
};
|
||||||
|
}
|
||||||
41
modules/nixos/hardware/hid-fanatecff.nix
Normal file
41
modules/nixos/hardware/hid-fanatecff.nix
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
|
with lib;
|
||||||
|
|
||||||
|
let
|
||||||
|
cfg = config.hardware.hid-fanatecff;
|
||||||
|
kernelPackage = pkgs.callPackage ./hid-fanatecff-pkg.nix {
|
||||||
|
kernel = config.boot.kernelPackages.kernel;
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
options.hardware.hid-fanatecff = {
|
||||||
|
enable = mkOption {
|
||||||
|
type = types.bool;
|
||||||
|
default = false;
|
||||||
|
example = true;
|
||||||
|
description = lib.mdDoc ''
|
||||||
|
Enables the Linux module drivers for Fanatec wheel bases.
|
||||||
|
Works with the CSL Elite and CSL/ClubSport DD/DD Pro,
|
||||||
|
and has experimental support for the ClubSport V2/V2.5,
|
||||||
|
Podium DD1/DD2 and CSR Elite.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
|
boot = {
|
||||||
|
extraModulePackages = [ kernelPackage ];
|
||||||
|
kernelModules = [ "hid-fanatecff" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
maintainers = with maintainers; [ theaninova ];
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user