Compare commits

...

2 commits

Author SHA1 Message Date
dadccdbe20 make usbmuxd optional 2023-11-20 19:43:38 +01:00
a61a40397f flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/c757e9bd77b16ca2e03c89bf8bc9ecb28e0c06ad' (2023-11-17)
  → 'github:NixOS/nixpkgs/e4ad989506ec7d71f7302cc3067abd82730a4beb' (2023-11-19)
2023-11-20 19:32:11 +01:00
4 changed files with 18 additions and 11 deletions

View file

@ -569,11 +569,11 @@
}, },
"nixpkgs_9": { "nixpkgs_9": {
"locked": { "locked": {
"lastModified": 1700204040, "lastModified": 1700390070,
"narHash": "sha256-xSVcS5HBYnD3LTer7Y2K8ZQCDCXMa3QUD1MzRjHzuhI=", "narHash": "sha256-de9KYi8rSJpqvBfNwscWdalIJXPo8NjdIZcEJum1mH0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "c757e9bd77b16ca2e03c89bf8bc9ecb28e0c06ad", "rev": "e4ad989506ec7d71f7302cc3067abd82730a4beb",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -19,6 +19,7 @@
social.enable = true; social.enable = true;
mail.enable = true; mail.enable = true;
gaming.enable = true; gaming.enable = true;
evremap.enable = true;
}; };
terminal.enable = true; terminal.enable = true;
}; };

View file

@ -37,8 +37,8 @@
cloud.enable = true; cloud.enable = true;
social.enable = true; social.enable = true;
gaming.enable = true; gaming.enable = true;
ios-compat.enable = true;
mail.enable = true; mail.enable = true;
evremap.enable = false;
}; };
terminal.enable = true; terminal.enable = true;
}; };

View file

@ -1,5 +1,6 @@
{ pkgs, config, ... }: { pkgs, config, lib, ... }:
let let
cfg = config.jade.desktop.evremap;
evremap = pkgs.rustPlatform.buildRustPackage { evremap = pkgs.rustPlatform.buildRustPackage {
pname = "evremap"; pname = "evremap";
version = "0.1.0"; version = "0.1.0";
@ -17,12 +18,17 @@ let
nativeBuildInputs = [ pkgs.pkg-config ]; nativeBuildInputs = [ pkgs.pkg-config ];
buildInputs = [ pkgs.libevdev ]; buildInputs = [ pkgs.libevdev ];
}; };
in { in with lib; {
systemd.services.evremap = { options.jade.desktop.evremap = {
script = "${evremap}/bin/evremap remap ${../../other/remaps-${config.networking.hostName}.toml}"; enable = mkEnableOption "Enable evremap";
wantedBy = [ "multi-user.target" ]; };
unitConfig = { config = mkIf cfg.enable {
Restart = "on-failure"; systemd.services.evremap = {
script = "${evremap}/bin/evremap remap ${../../other/remaps-${config.networking.hostName}.toml}";
wantedBy = [ "multi-user.target" ];
unitConfig = {
Restart = "on-failure";
};
}; };
}; };
} }