mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-18 03:34:58 +00:00
61e93df189
once again using nix-doc-munge (69d080323a
)
30 lines
714 B
Nix
30 lines
714 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
with lib;
|
|
|
|
{
|
|
meta.maintainers = [ maintainers.mic92 ];
|
|
|
|
###### interface
|
|
options = {
|
|
programs.adb = {
|
|
enable = mkOption {
|
|
default = false;
|
|
type = types.bool;
|
|
description = lib.mdDoc ''
|
|
Whether to configure system to use Android Debug Bridge (adb).
|
|
To grant access to a user, it must be part of adbusers group:
|
|
`users.users.alice.extraGroups = ["adbusers"];`
|
|
'';
|
|
};
|
|
};
|
|
};
|
|
|
|
###### implementation
|
|
config = mkIf config.programs.adb.enable {
|
|
services.udev.packages = [ pkgs.android-udev-rules ];
|
|
environment.systemPackages = [ pkgs.android-tools ];
|
|
users.groups.adbusers = {};
|
|
};
|
|
}
|