depot/nixos/modules/programs/gpaste.nix
Luke Granger-Brown 57725ef3ec Squashed 'third_party/nixpkgs/' content from commit 76612b17c0ce
git-subtree-dir: third_party/nixpkgs
git-subtree-split: 76612b17c0ce71689921ca12d9ffdc9c23ce40b2
2024-11-10 23:59:47 +00:00

29 lines
825 B
Nix

# GPaste.
{ config, lib, pkgs, ... }:
{
###### interface
options = {
programs.gpaste = {
enable = lib.mkOption {
type = lib.types.bool;
default = false;
description = ''
Whether to enable GPaste, a clipboard manager.
'';
};
};
};
###### implementation
config = lib.mkIf config.programs.gpaste.enable {
environment.systemPackages = [ pkgs.gpaste ];
services.dbus.packages = [ pkgs.gpaste ];
systemd.packages = [ pkgs.gpaste ];
# gnome-control-center crashes in Keyboard Shortcuts pane without the GSettings schemas.
services.xserver.desktopManager.gnome.sessionPath = [ pkgs.gpaste ];
# gpaste-reloaded applet doesn't work without the typelib
services.xserver.desktopManager.cinnamon.sessionPath = [ pkgs.gpaste ];
};
}