Skip to content

Commit

Permalink
sddm-astronaut: 1.0 -> 1.0-unstable-2025-01-05 (#372568)
Browse files Browse the repository at this point in the history
  • Loading branch information
FliegendeWurst authored Jan 15, 2025
2 parents d657f4d + 0f34664 commit 6396330
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 6 deletions.
6 changes: 6 additions & 0 deletions maintainers/maintainer-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23830,6 +23830,12 @@
githubId = 2212422;
name = "uwap";
};
uxodb = {
name = "uxodb";
matrix = "@uxodb:matrix.org";
github = "uxodb";
githubId = 20535246;
};
V = {
name = "V";
email = "[email protected]";
Expand Down
26 changes: 20 additions & 6 deletions pkgs/data/themes/sddm-astronaut/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,25 @@
lib,
stdenvNoCC,
themeConfig ? null,
embeddedTheme ? "astronaut",
}:
stdenvNoCC.mkDerivation rec {
pname = "sddm-astronaut";
version = "1.0";
version = "1.0-unstable-2025-01-05";

src = pkgs.fetchFromGitHub {
owner = "Keyitdev";
repo = "sddm-astronaut-theme";
rev = "48ea0a792711ac0c58cc74f7a03e2e7ba3dc2ac0";
hash = "sha256-kXovz813BS+Mtbk6+nNNdnluwp/7V2e3KJLuIfiWRD0=";
rev = "11c0bf6147bbea466ce2e2b0559e9a9abdbcc7c3";
hash = "sha256-gBSz+k/qgEaIWh1Txdgwlou/Lfrfv3ABzyxYwlrLjDk=";
};

dontWrapQtApps = true;

propagatedBuildInputs = with pkgs.kdePackages; [
qt5compat
qtsvg
qtmultimedia
qtvirtualkeyboard
];

installPhase =
Expand All @@ -27,13 +30,21 @@ stdenvNoCC.mkDerivation rec {
configFile = iniFormat.generate "" { General = themeConfig; };

basePath = "$out/share/sddm/themes/sddm-astronaut-theme";
sedString = "ConfigFile=Themes/";
in
''
mkdir -p ${basePath}
cp -r $src/* ${basePath}
''
+ lib.optionalString (embeddedTheme != "astronaut") ''
# Replaces astronaut.conf with embedded theme in metadata.desktop on line 9.
# ConfigFile=Themes/astronaut.conf.
sed -i "s|^${sedString}.*\\.conf$|${sedString}${embeddedTheme}.conf|" ${basePath}/metadata.desktop
''
+ lib.optionalString (themeConfig != null) ''
ln -sf ${configFile} ${basePath}/theme.conf.user
chmod u+w ${basePath}/Themes/
ln -sf ${configFile} ${basePath}/Themes/${embeddedTheme}.conf.user
'';

meta = {
Expand All @@ -42,6 +53,9 @@ stdenvNoCC.mkDerivation rec {
license = lib.licenses.gpl3;

platforms = lib.platforms.linux;
maintainers = with lib.maintainers; [ danid3v ];
maintainers = with lib.maintainers; [
danid3v
uxodb
];
};
}

0 comments on commit 6396330

Please sign in to comment.