forked from mirrors/nixpkgs
gnome3: Set nixos desktop background and screensaver
This commit is contained in:
parent
ed7865ee00
commit
97dd0dae74
|
@ -25,6 +25,25 @@ let
|
|||
'';
|
||||
};
|
||||
|
||||
nixos-gsettings-desktop-schemas = pkgs.stdenv.mkDerivation {
|
||||
name = "nixos-gsettings-desktop-schemas";
|
||||
buildInputs = [ pkgs.nixos-artwork ];
|
||||
buildCommand = ''
|
||||
mkdir -p $out/share/nixos-gsettings-schemas/nixos-gsettings-desktop-schemas
|
||||
cp -rf ${gnome3.gsettings_desktop_schemas}/share/gsettings-schemas/gsettings-desktop-schemas*/glib-2.0 $out/share/nixos-gsettings-schemas/nixos-gsettings-desktop-schemas/
|
||||
chmod -R a+w $out/share/nixos-gsettings-schemas/nixos-gsettings-desktop-schemas
|
||||
cat - > $out/share/nixos-gsettings-schemas/nixos-gsettings-desktop-schemas/glib-2.0/schemas/org.gnome.desktop.background.nixos.gschema.override <<- EOF
|
||||
[org.gnome.desktop.background]
|
||||
picture-uri='${pkgs.nixos-artwork}/share/artwork/gnome/Gnome_Dark.png'
|
||||
EOF
|
||||
cat - > $out/share/nixos-gsettings-schemas/nixos-gsettings-desktop-schemas/glib-2.0/schemas/org.gnome.desktop.screensaver.nixos.gschema.override <<- EOF
|
||||
[org.gnome.desktop.screensaver]
|
||||
picture-uri='${pkgs.nixos-artwork}/share/artwork/gnome/Gnome_Dark.png'
|
||||
EOF
|
||||
${pkgs.glib}/bin/glib-compile-schemas $out/share/nixos-gsettings-schemas/nixos-gsettings-desktop-schemas/glib-2.0/schemas/
|
||||
'';
|
||||
};
|
||||
|
||||
in {
|
||||
|
||||
options = {
|
||||
|
@ -109,6 +128,9 @@ in {
|
|||
# Override default mimeapps
|
||||
export XDG_DATA_DIRS=$XDG_DATA_DIRS''${XDG_DATA_DIRS:+:}${mimeAppsList}/share
|
||||
|
||||
# Override gsettings-desktop-schema
|
||||
export XDG_DATA_DIRS=${nixos-gsettings-desktop-schemas}/share/nixos-gsettings-schemas/nixos-gsettings-desktop-schemas''${XDG_DATA_DIRS:+:}$XDG_DATA_DIRS
|
||||
|
||||
# Let nautilus find extensions
|
||||
export NAUTILUS_EXTENSION_DIR=${config.system.path}/lib/nautilus/extensions-3.0/
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
|
|||
preFixup = ''
|
||||
wrapProgram "$out/bin/gnome-session" \
|
||||
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH" \
|
||||
--prefix XDG_DATA_DIRS : "$out/share:$GSETTINGS_SCHEMAS_PATH"
|
||||
--suffix XDG_DATA_DIRS : "$out/share:$GSETTINGS_SCHEMAS_PATH"
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
|
|
@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
|
|||
--prefix PATH : "${unzip}/bin" \
|
||||
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH" \
|
||||
--set GDK_PIXBUF_MODULE_FILE "$GDK_PIXBUF_MODULE_FILE" \
|
||||
--prefix XDG_DATA_DIRS : "${gnome_themes_standard}/share:$out/share:$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH"
|
||||
--suffix XDG_DATA_DIRS : "${gnome_themes_standard}/share:$out/share:$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH"
|
||||
|
||||
wrapProgram "$out/libexec/gnome-shell-calendar-server" \
|
||||
--prefix XDG_DATA_DIRS : "${evolution_data_server}/share:$out/share:$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH"
|
||||
|
|
Loading…
Reference in a new issue