Luke Granger-Brown
57725ef3ec
git-subtree-dir: third_party/nixpkgs git-subtree-split: 76612b17c0ce71689921ca12d9ffdc9c23ce40b2
24 lines
657 B
Nix
24 lines
657 B
Nix
{ lib
|
|
, runCommand
|
|
, gsettings-desktop-schemas
|
|
, mate-wayland-session
|
|
, glib
|
|
}:
|
|
|
|
let
|
|
gsettingsOverridePackages = [
|
|
gsettings-desktop-schemas
|
|
mate-wayland-session
|
|
];
|
|
in
|
|
runCommand "mate-gsettings-overrides" { preferLocalBuild = true; } ''
|
|
data_dir="$out/share/gsettings-schemas/nixos-gsettings-overrides"
|
|
schema_dir="$data_dir/glib-2.0/schemas"
|
|
mkdir -p "$schema_dir"
|
|
|
|
${lib.concatMapStringsSep "\n" (pkg: "cp -rf \"${glib.getSchemaPath pkg}\"/*.xml \"${glib.getSchemaPath pkg}\"/*.gschema.override \"$schema_dir\"") gsettingsOverridePackages}
|
|
|
|
chmod -R a+w "$data_dir"
|
|
|
|
${glib.dev}/bin/glib-compile-schemas --strict "$schema_dir"
|
|
''
|