depot/third_party/nixpkgs/pkgs/servers/matrix-synapse/matrix-appservice-slack/default.nix
Default email ae91cbe6cc Project import generated by Copybara.
GitOrigin-RevId: 536fe36e23ab0fc8b7f35c24603422eee9fc17a2
2021-02-05 18:12:51 +01:00

31 lines
781 B
Nix

{ pkgs, nodejs, stdenv, fetchFromGitHub, lib, ... }:
let
src = fetchFromGitHub {
owner = "matrix-org";
repo = "matrix-appservice-slack";
rev = "1.4.0";
sha256 = "1xm75rgg7yrz40y2w1njiwfwz17a8wwlvr7a6zyxvkl8cqrgzp6d";
};
nodePackages = import ./node-composition.nix {
inherit pkgs nodejs;
inherit (stdenv.hostPlatform) system;
};
in
nodePackages.package.override {
inherit src;
nativeBuildInputs = [ pkgs.makeWrapper ];
postInstall = ''
makeWrapper '${nodejs}/bin/node' "$out/bin/matrix-appservice-slack" \
--add-flags "$out/lib/node_modules/matrix-appservice-slack/lib/app.js"
'';
meta = with lib; {
description = "A Matrix <--> Slack bridge";
maintainers = with maintainers; [ ];
license = licenses.asl20;
};
}