Unverified Commit 76ad551b authored by Nick Cao's avatar Nick Cao Committed by GitHub
Browse files

paper-plane: use fetchCargoVendor and refactor (#386767)

parents 99bb5ef5 f990a063
Loading
Loading
Loading
Loading
+0 −1850

File deleted.

Preview size limit exceeded, changes collapsed.

+9 −12
Original line number Diff line number Diff line
{
  lib,
  stdenv,
  fetchFromGitHub,
  gtk4,
  libadwaita,
  tdlib,
  rlottie,
  stdenv,
  rustPlatform,
  meson,
  ninja,
@@ -28,7 +28,7 @@ let
  src = fetchFromGitHub {
    owner = "paper-plane-developers";
    repo = "paper-plane";
    rev = "v${version}";
    tag = "v${version}";
    hash = "sha256-qcAHxNnF980BHMqLF86M06YQnEN5L/8nkyrX6HQjpBA=";
  };

@@ -71,12 +71,9 @@ in
stdenv.mkDerivation {
  inherit pname version src;

  cargoDeps = rustPlatform.importCargoLock {
    lockFile = ./Cargo.lock;
    outputHashes = {
      "gtk-rlottie-0.1.0" = "sha256-/F0VSXU0Z59QyFYXrB8NLe/Nw/uVjGY68BriOySSXyI=";
      "origami-0.1.0" = "sha256-xh7eBjumqCOoAEvRkivs/fgvsKXt7UU67FCFt20oh5s=";
    };
  cargoDeps = rustPlatform.fetchCargoVendor {
    inherit pname version src;
    hash = "sha256-QEX7w8eMV7DJFONjq23o8eCV+lliugS0pcdufFhcZrM=";
  };

  nativeBuildInputs = [
@@ -122,7 +119,7 @@ stdenv.mkDerivation {
    stdenv.cc.isClang && lib.versionAtLeast stdenv.cc.version "16"
  ) "-Wno-error=incompatible-function-pointer-types";

  meta = with lib; {
  meta = {
    homepage = "https://github.com/paper-plane-developers/paper-plane";
    description = "Chat over Telegram on a modern and elegant client";
    longDescription = ''
@@ -130,9 +127,9 @@ stdenv.mkDerivation {
      for its user interface and strives to meet the design principles
      of the GNOME desktop.
    '';
    license = licenses.gpl3Plus;
    maintainers = with maintainers; [ aleksana ];
    license = lib.licenses.gpl3Plus;
    maintainers = with lib.maintainers; [ aleksana ];
    mainProgram = "paper-plane";
    platforms = platforms.unix;
    platforms = lib.platforms.unix;
  };
}