2021-12-06 16:07:01 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchFromGitHub
|
2020-08-20 17:08:02 +00:00
|
|
|
, nix-update-script
|
2020-04-24 23:36:52 +00:00
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, nixos-artwork
|
|
|
|
, glib
|
2021-02-05 17:12:51 +00:00
|
|
|
, pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
, dbus
|
|
|
|
, polkit
|
|
|
|
, accountsservice
|
|
|
|
, python3
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "elementary-default-settings";
|
2021-12-06 16:07:01 +00:00
|
|
|
version = "6.0.2";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "elementary";
|
2022-01-26 04:04:25 +00:00
|
|
|
repo = "default-settings";
|
2020-04-24 23:36:52 +00:00
|
|
|
rev = version;
|
2021-12-06 16:07:01 +00:00
|
|
|
sha256 = "sha256-qaPj/Qp7RYzHgElFdM8bHV42oiPUbCMTC9Q+MUj4Q6Y=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
accountsservice
|
|
|
|
dbus
|
|
|
|
glib # polkit requires
|
|
|
|
meson
|
|
|
|
ninja
|
2021-02-05 17:12:51 +00:00
|
|
|
pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
polkit
|
|
|
|
python3
|
|
|
|
];
|
|
|
|
|
|
|
|
mesonFlags = [
|
|
|
|
"--sysconfdir=${placeholder "out"}/etc"
|
2020-06-18 07:06:33 +00:00
|
|
|
"-Ddefault-wallpaper=${nixos-artwork.wallpapers.simple-dark-gray.gnomeFilePath}"
|
2020-04-24 23:36:52 +00:00
|
|
|
"-Dplank-dockitems=false"
|
|
|
|
];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
chmod +x meson/post_install.py
|
|
|
|
patchShebangs meson/post_install.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
preInstall = ''
|
2022-02-10 20:34:41 +00:00
|
|
|
# Install our override for plank dockitems as the desktop file path is different.
|
2020-04-24 23:36:52 +00:00
|
|
|
schema_dir=$out/share/glib-2.0/schemas
|
|
|
|
install -D ${./overrides/plank-dockitems.gschema.override} $schema_dir/plank-dockitems.gschema.override
|
|
|
|
|
|
|
|
# Our launchers that use paths at /run/current-system/sw/bin
|
|
|
|
mkdir -p $out/etc/skel/.config/plank/dock1
|
|
|
|
cp -avr ${./launchers} $out/etc/skel/.config/plank/dock1/launchers
|
|
|
|
'';
|
|
|
|
|
|
|
|
postFixup = ''
|
|
|
|
# https://github.com/elementary/default-settings/issues/55
|
2021-12-06 16:07:01 +00:00
|
|
|
rm -r $out/share/cups
|
|
|
|
rm -r $out/share/applications
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
passthru = {
|
2022-12-28 21:21:41 +00:00
|
|
|
updateScript = nix-update-script { };
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Default settings and configuration files for elementary";
|
|
|
|
homepage = "https://github.com/elementary/default-settings";
|
|
|
|
license = licenses.gpl2Plus;
|
|
|
|
platforms = platforms.linux;
|
2021-09-22 15:38:15 +00:00
|
|
|
maintainers = teams.pantheon.members;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|