2014-02-06 23:37:17 +00:00
|
|
|
{ config, pkgs, ... }:
|
|
|
|
|
|
|
|
with pkgs.lib;
|
|
|
|
|
|
|
|
let
|
|
|
|
cfg = config.services.xserver.desktopManager.gnome3;
|
|
|
|
gnome3 = pkgs.gnome3;
|
|
|
|
in {
|
|
|
|
|
|
|
|
options = {
|
|
|
|
|
|
|
|
services.xserver.desktopManager.gnome3.enable = mkOption {
|
|
|
|
default = false;
|
|
|
|
example = true;
|
|
|
|
description = "Enable Gnome 3 desktop manager.";
|
|
|
|
};
|
|
|
|
|
2014-04-08 23:02:20 +01:00
|
|
|
environment.gnome3.excludePackages = mkOption {
|
|
|
|
default = [];
|
|
|
|
example = "[ pkgs.gnome3.totem ]";
|
|
|
|
type = types.listOf types.package;
|
|
|
|
description = "Which packages gnome should exclude from the default environment";
|
|
|
|
};
|
|
|
|
|
2014-02-06 23:37:17 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
|
|
|
|
# Enable helpful DBus services.
|
|
|
|
security.polkit.enable = true;
|
|
|
|
services.udisks2.enable = true;
|
2014-04-06 20:20:45 +01:00
|
|
|
services.accounts-daemon.enable = true;
|
2014-04-08 21:44:22 +01:00
|
|
|
services.gnome3.at-spi2-core.enable = true;
|
2014-04-08 12:23:12 +01:00
|
|
|
services.gnome3.evolution-data-server.enable = true;
|
2014-04-07 22:54:07 +01:00
|
|
|
services.gnome3.sushi.enable = true;
|
2014-04-09 14:57:02 +01:00
|
|
|
services.gnome3.tracker.enable = mkDefault true;
|
2014-04-08 14:02:15 +01:00
|
|
|
services.telepathy.enable = true;
|
2014-02-06 23:37:17 +00:00
|
|
|
networking.networkmanager.enable = true;
|
|
|
|
services.upower.enable = config.powerManagement.enable;
|
|
|
|
|
|
|
|
fonts.extraFonts = [ pkgs.dejavu_fonts ];
|
|
|
|
|
|
|
|
services.xserver.desktopManager.session = singleton
|
|
|
|
{ name = "gnome3";
|
|
|
|
start = ''
|
|
|
|
# Set GTK_DATA_PREFIX so that GTK+ can find the themes
|
|
|
|
export GTK_DATA_PREFIX=${config.system.path}
|
|
|
|
|
|
|
|
# find theme engines
|
2014-02-19 15:53:08 +00:00
|
|
|
export GTK_PATH=${config.system.path}/lib/gtk-3.0:${config.system.path}/lib/gtk-2.0
|
2014-02-06 23:37:17 +00:00
|
|
|
|
|
|
|
export XDG_MENU_PREFIX=gnome
|
|
|
|
|
|
|
|
${gnome3.gnome_session}/bin/gnome-session&
|
|
|
|
waitPID=$!
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2014-04-04 22:21:38 +01:00
|
|
|
environment.variables.GIO_EXTRA_MODULES = [ "${gnome3.dconf}/lib/gio/modules"
|
|
|
|
"${pkgs.glib_networking}/lib/gio/modules" ];
|
2014-02-06 23:37:17 +00:00
|
|
|
environment.systemPackages =
|
2014-04-08 23:02:20 +01:00
|
|
|
[ gnome3.dconf
|
|
|
|
pkgs.glib_networking
|
|
|
|
pkgs.ibus
|
|
|
|
gnome3.gnome-backgrounds
|
|
|
|
gnome3.gnome_control_center
|
|
|
|
gnome3.gnome_icon_theme
|
|
|
|
gnome3.gnome_settings_daemon
|
|
|
|
gnome3.gnome_shell
|
|
|
|
gnome3.gnome_themes_standard
|
|
|
|
] ++ (lists.difference [
|
|
|
|
gnome3.baobab
|
2014-02-06 23:37:17 +00:00
|
|
|
gnome3.eog
|
2014-02-19 15:38:17 +00:00
|
|
|
gnome3.epiphany
|
2014-04-08 23:02:20 +01:00
|
|
|
gnome3.evince
|
2014-02-19 15:38:17 +00:00
|
|
|
gnome3.gucharmap
|
|
|
|
gnome3.nautilus
|
2014-04-08 23:02:20 +01:00
|
|
|
gnome3.totem
|
|
|
|
gnome3.vino
|
2014-02-19 15:38:17 +00:00
|
|
|
gnome3.yelp
|
2014-04-08 23:02:20 +01:00
|
|
|
gnome3.gnome-calculator
|
|
|
|
gnome3.gnome-contacts
|
|
|
|
gnome3.gnome-font-viewer
|
|
|
|
gnome3.gnome-screenshot
|
|
|
|
gnome3.gnome-system-log
|
|
|
|
gnome3.gnome-system-monitor
|
2014-02-06 23:37:17 +00:00
|
|
|
gnome3.gnome_terminal
|
2014-04-08 23:02:20 +01:00
|
|
|
|
|
|
|
gnome3.file-roller
|
|
|
|
] config.environment.gnome3.excludePackages);
|
2014-02-06 23:37:17 +00:00
|
|
|
};
|
|
|
|
|
2014-02-16 20:37:18 +00:00
|
|
|
|
2014-02-06 23:37:17 +00:00
|
|
|
}
|