Unverified Commit 6396330e authored by Arne Keller's avatar Arne Keller Committed by GitHub
Browse files

sddm-astronaut: 1.0 -> 1.0-unstable-2025-01-05 (#372568)

parents d657f4db 0f346649
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -23830,6 +23830,12 @@
    githubId = 2212422;
    name = "uwap";
  };
  uxodb = {
    name = "uxodb";
    matrix = "@uxodb:matrix.org";
    github = "uxodb";
    githubId = 20535246;
  };
  V = {
    name = "V";
    email = "v@anomalous.eu";
+20 −6
Original line number Diff line number Diff line
@@ -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 =
@@ -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 = {
@@ -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
    ];
  };
}