Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, rustPlatform 3, fetchFromGitHub 4, libsixel 5, withSixel ? false 6}: 7 8rustPlatform.buildRustPackage rec { 9 pname = "viu"; 10 version = "1.4.0"; 11 12 src = fetchFromGitHub { 13 owner = "atanunq"; 14 repo = "viu"; 15 rev = "v${version}"; 16 sha256 = "sha256-lAuIl25368Gv717a8p2So1o1VMDJJAOlDdqfItYizo4="; 17 }; 18 19 # tests need an interactive terminal 20 doCheck = false; 21 22 cargoSha256 = "sha256-ildtjaYGbrQacJOdGDVwFv+kod+vZHqukWN6ARtJqI4="; 23 24 buildFeatures = lib.optional withSixel "sixel"; 25 buildInputs = lib.optional withSixel libsixel; 26 27 meta = with lib; { 28 description = "A command-line application to view images from the terminal written in Rust"; 29 homepage = "https://github.com/atanunq/viu"; 30 license = licenses.mit; 31 maintainers = with maintainers; [ chuangzhu ]; 32 }; 33}