nixpkgs/pkgs/applications/networking/instant-messengers/riot/riot-web.nix
2019-07-19 22:13:37 +02:00

34 lines
948 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 {
name= "riot-web-${version}";
version = "1.3.0";
src = fetchurl {
url = "https://github.com/vector-im/riot-web/releases/download/v${version}/riot-v${version}.tar.gz";
sha256 = "1rppxcc4m00bf73ghgli967wwrri2jdj865623pn8nk4kny4wxyq";
};
installPhase = let
configFile = if (conf != null)
then writeText "riot-config.json" conf
else "$out/config.sample.json";
in ''
mkdir -p $out/
cp -R . $out/
ln -s ${configFile} $out/config.json
'';
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 = [];
};
}