From d8a3ffd85ddf96c306d8c7d9db32615d8bbaf434 Mon Sep 17 00:00:00 2001 From: Kopatz <7265381+Kropatz@users.noreply.github.com> Date: Tue, 4 Jun 2024 11:21:38 +0200 Subject: [PATCH] android --- modules/graphical/code-android.nix | 15 +++++++++++++++ modules/graphical/default.nix | 1 + systems/pc/configuration.nix | 5 ++++- 3 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 modules/graphical/code-android.nix diff --git a/modules/graphical/code-android.nix b/modules/graphical/code-android.nix new file mode 100644 index 0000000..8224f88 --- /dev/null +++ b/modules/graphical/code-android.nix @@ -0,0 +1,15 @@ +{ config, pkgs, inputs, lib, ... }: +with lib; +let cfg = config.custom.graphical.code.android; +in { + options.custom.graphical.code.android = { + enable = mkEnableOption "Enables code"; + }; + + config = mkIf cfg.enable { + documentation.dev.enable = true; + programs.adb.enable = true; + environment.systemPackages = with pkgs; [ android-studio ]; + users.users.${config.mainUser.name}.extraGroups = [ "adbusers" "kvm" ]; + }; +} diff --git a/modules/graphical/default.nix b/modules/graphical/default.nix index 3f21ec8..1207615 100644 --- a/modules/graphical/default.nix +++ b/modules/graphical/default.nix @@ -4,6 +4,7 @@ imports = [ ./audio.nix ./code.nix + ./code-android.nix ./awesome.nix ./emulators.nix ./i3.nix diff --git a/systems/pc/configuration.nix b/systems/pc/configuration.nix index cd691f6..3ccd703 100644 --- a/systems/pc/configuration.nix +++ b/systems/pc/configuration.nix @@ -58,7 +58,10 @@ }; graphical = { audio.enable = true; - code.enable = true; + code = { + enable = true; + android.enable = true; + }; emulators.enable = true; gamemode.enable = true; games.enable = true;