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

Merge pull request #332031 from r-ryantm/auto-update/mdcat

mdcat: 2.1.2 -> 2.3.0
parents 06b1a622 6fe75e3b
Loading
Loading
Loading
Loading
+8 −8
Original line number Diff line number Diff line
@@ -13,20 +13,20 @@

rustPlatform.buildRustPackage rec {
  pname = "mdcat";
  version = "2.1.2";
  version = "2.3.0";

  src = fetchFromGitHub {
    owner = "swsnr";
    repo = "mdcat";
    rev = "mdcat-${version}";
    hash = "sha256-qdNORp9THxHWR95uVcYtCy59OQqdop1012thZN5i64w=";
    hash = "sha256-OgqWlWORLbohok9gJWiVUf0EdFP7Duk0Iw1PiSl4350=";
  };

  nativeBuildInputs = [ pkg-config asciidoctor installShellFiles ];
  buildInputs = [ openssl ]
    ++ lib.optionals stdenv.isDarwin [ Security SystemConfiguration ];

  cargoHash = "sha256-/avxRvT35LxCBWkTYJDCtdd95VC67epZIPCMv994uBo=";
  cargoHash = "sha256-jLKqJQ+T2KaS1bZ6MSQ6l/1iXvfLoyeI68WvO5smuwU=";

  nativeCheckInputs = [ ansi2html ];
  # Skip tests that use the network and that include files.
@@ -44,12 +44,12 @@ rustPlatform.buildRustPackage rec {
  postInstall = ''
    installManPage $releaseDir/build/mdcat-*/out/mdcat.1
    ln -sr $out/bin/{mdcat,mdless}

  '' + lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
    for bin in mdcat mdless; do
      installShellCompletion \
        --bash $releaseDir/build/mdcat-*/out/completions/$bin.bash \
        --fish $releaseDir/build/mdcat-*/out/completions/$bin.fish \
        --zsh $releaseDir/build/mdcat-*/out/completions/_$bin
      installShellCompletion --cmd $bin \
        --bash <($out/bin/$bin --completions bash) \
        --fish <($out/bin/$bin --completions fish) \
        --zsh <($out/bin/$bin --completions zsh)
    done
  '';