Unverified Commit 52c5665a authored by Sandro Jäckel's avatar Sandro Jäckel Committed by GitHub
Browse files

keyguard: 1.7.2 -> 1.7.6 (#378362)

parents 7d071611 7213a586
Loading
Loading
Loading
Loading
+352 −338

File changed.

Preview size limit exceeded, changes collapsed.

+31 −30
Original line number Diff line number Diff line
@@ -3,11 +3,8 @@
  stdenv,
  fetchFromGitHub,
  gradle,
  binutils,
  fakeroot,
  jdk17,
  fontconfig,
  autoPatchelfHook,
  libXinerama,
  libXrandr,
  file,
@@ -19,40 +16,28 @@
  makeDesktopItem,
  copyDesktopItems,
}:

stdenv.mkDerivation (finalAttrs: {
  pname = "keyguard";
  version = "1.7.2";
  version = "1.7.6";

  src = fetchFromGitHub {
    owner = "AChep";
    repo = "keyguard-app";
    tag = "r20241223";
    hash = "sha256-7fMSpTKEEjSXfYotZ/qxX1m+i8GheCLboo+XoA3gTbc=";
    tag = "r20250128";
    hash = "sha256-/z7ihmZecIc7Wjd2M9aHcSFYyg2YsWiC9Ia09Ey42qQ=";
  };

  postPatch = ''
    substituteInPlace desktopLibJvm/build.gradle.kts \
      --replace-fail 'resources.srcDir(rootDir.resolve("desktopLibNative/build/bin/universal"))' "" \
      --replace-fail 'resourcesTask.dependsOn(":desktopLibNative:''${Tasks.compileNativeUniversal}")' ""
  '';

  gradleBuildTask = ":desktopApp:createDistributable";

  gradleUpdateTask = finalAttrs.gradleBuildTask;

  desktopItems = [
    (makeDesktopItem {
      name = "keyguard";
      exec = "Keyguard";
      icon = "keyguard";
      comment = "Keyguard";
      desktopName = "Keyguard";
    })
  ];

  nativeBuildInputs = [
    gradle
    binutils
    fakeroot
    jdk17
    autoPatchelfHook
    copyDesktopItems
  ];

  mitmCache = gradle.fetchDeps {
    inherit (finalAttrs) pname;
    data = ./deps.json;
@@ -60,13 +45,15 @@ stdenv.mkDerivation (finalAttrs: {
    useBwrap = false;
  };

  passthru.updateScript = ./update.sh;

  doCheck = false;
  env.JAVA_HOME = jdk17;

  gradleFlags = [ "-Dorg.gradle.java.home=${jdk17}" ];

  env.JAVA_HOME = jdk17;
  nativeBuildInputs = [
    gradle
    jdk17
    copyDesktopItems
  ];

  buildInputs = [
    fontconfig
@@ -80,15 +67,29 @@ stdenv.mkDerivation (finalAttrs: {
    alsa-lib
  ];

  doCheck = false;

  desktopItems = [
    (makeDesktopItem {
      name = "keyguard";
      exec = "Keyguard";
      icon = "keyguard";
      comment = "Keyguard";
      desktopName = "Keyguard";
    })
  ];

  installPhase = ''
    runHook preInstall

    cp -r ./desktopApp/build/compose/binaries/main/app/Keyguard $out
    cp -r desktopApp/build/compose/binaries/main/app/Keyguard $out
    install -Dm0644 $out/lib/Keyguard.png $out/share/pixmaps/keyguard.png

    runHook postInstall
  '';

  passthru.updateScript = ./update.sh;

  meta = {
    description = "Alternative client for the Bitwarden platform, created to provide the best user experience possible";
    homepage = "https://github.com/AChep/keyguard-app";
+1 −1
Original line number Diff line number Diff line
#!/usr/bin/env nix-shell
#!nix-shell -I nixpkgs=./. -i bash -p bash nixVersions.latest curl coreutils jq common-updater-scripts
#!nix-shell -I nixpkgs=./. -i bash -p bash nix curl coreutils jq common-updater-scripts

set -eou pipefail