about summary refs log tree commit diff
path: root/nixos/modules/programs/partition-manager.nix
blob: 1a66a3f04c41a1e72a7959678f202824efa24704 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
{ config, lib, pkgs, ... }:

let
  cfg = config.programs.partition-manager;
in {
  meta.maintainers = [ lib.maintainers.oxalica ];

  options = {
    programs.partition-manager = {
      enable = lib.mkEnableOption "KDE Partition Manager";

      package = lib.mkPackageOption pkgs [ "libsForQt5" "partitionmanager" ] { };
    };
  };

  config = lib.mkIf config.programs.partition-manager.enable {
    services.dbus.packages = [ cfg.package.kpmcore ];
    # `kpmcore` need to be installed to pull in polkit actions.
    environment.systemPackages = [ cfg.package.kpmcore cfg.package ];
  };
}