nixpkgs/pkgs/applications/networking/instant-messengers/riot/riot-web.nix
worldofpeace b34344718b
Merge pull request #75377 from pacien/riot-v1.5.6
riot-{web,desktop}: 1.5.5 -> 1.5.6
2019-12-17 01:43:06 -05:00

38 lines
988 B
Nix

{ lib, stdenv, fetchurl, writeText, conf ? null }:
# Note for maintainers:
# Versions of `riot-web` and `riot-desktop` should be kept in sync.
stdenv.mkDerivation rec {
pname = "riot-web";
version = "1.5.6";
src = fetchurl {
url = "https://github.com/vector-im/riot-web/releases/download/v${version}/riot-v${version}.tar.gz";
sha256 = "063ynbil038y201skyldj2ysr0hwgwq981w1iw104xd17x31zmn0";
};
installPhase = let
configFile = if (conf != null)
then writeText "riot-config.json" conf
else "$out/config.sample.json";
in ''
runHook preInstall
mkdir -p $out/
cp -R . $out/
ln -s ${configFile} $out/config.json
runHook postInstall
'';
meta = {
description = "A glossy Matrix collaboration client for the web";
homepage = http://riot.im/;
maintainers = with stdenv.lib.maintainers; [ bachp pacien ];
license = stdenv.lib.licenses.asl20;
platforms = stdenv.lib.platforms.all;
hydraPlatforms = [];
};
}