nixpkgs-suyu/pkgs/servers/matrix-synapse/matrix-appservice-slack/default.nix

31 lines
792 B
Nix
Raw Normal View History

{ pkgs, nodejs, stdenv, fetchFromGitHub, lib, ... }:
2019-10-06 20:57:15 +02:00
let
src = fetchFromGitHub {
owner = "matrix-org";
repo = "matrix-appservice-slack";
rev = "1.7.0";
sha256 = "sha256-0BcnG/DGvc3uh/eP0KIB5gPSpXNPlaAl78D4bVCnLHg=";
};
2019-10-06 20:57:15 +02:00
nodePackages = import ./node-composition.nix {
inherit pkgs nodejs;
inherit (stdenv.hostPlatform) system;
};
2019-10-08 15:26:19 +02:00
in
nodePackages.package.override {
inherit src;
2019-10-06 20:57:15 +02:00
nativeBuildInputs = [ pkgs.makeWrapper ];
postInstall = ''
2019-10-08 15:26:19 +02:00
makeWrapper '${nodejs}/bin/node' "$out/bin/matrix-appservice-slack" \
--add-flags "$out/lib/node_modules/matrix-appservice-slack/lib/app.js"
2019-10-06 20:57:15 +02:00
'';
meta = with lib; {
description = "A Matrix <--> Slack bridge";
maintainers = with maintainers; [ beardhatcode ];
2019-10-08 15:26:19 +02:00
license = licenses.asl20;
2019-10-06 20:57:15 +02:00
};
}