mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-19 02:44:17 +03:00
32 lines
834 B
Nix
32 lines
834 B
Nix
{ lib, stdenv, fetchurl, writeText, jq, conf ? {} }:
|
|
|
|
let
|
|
configOverrides = writeText "cinny-config-overrides.json" (builtins.toJSON conf);
|
|
in stdenv.mkDerivation rec {
|
|
pname = "cinny";
|
|
version = "2.2.3";
|
|
|
|
src = fetchurl {
|
|
url = "https://github.com/ajbura/cinny/releases/download/v${version}/cinny-v${version}.tar.gz";
|
|
hash = "sha256-Q6f24LRYCxdgAguUVl7jf7srkd2L1IptiBgHJQq2dHE=";
|
|
};
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
mkdir -p $out/
|
|
cp -R . $out/
|
|
${jq}/bin/jq -s '.[0] * .[1]' "config.json" "${configOverrides}" > "$out/config.json"
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Yet another Matrix client for the web";
|
|
homepage = "https://cinny.in/";
|
|
maintainers = with maintainers; [ abbe ];
|
|
license = licenses.mit;
|
|
platforms = platforms.all;
|
|
};
|
|
}
|