2019-09-04 18:13:50 +02:00
|
|
|
{ stdenv, substituteAll, buildEnv, fetchFromGitHub, python3Packages }:
|
2018-09-06 15:10:37 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "wee-slack";
|
2020-03-25 20:08:26 -07:00
|
|
|
version = "2.5.0";
|
2018-09-06 15:10:37 +02:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
repo = "wee-slack";
|
|
|
|
owner = "wee-slack";
|
|
|
|
rev = "v${version}";
|
2020-03-25 20:08:26 -07:00
|
|
|
sha256 = "0sxgi5fg8qvzqmxy7sdma6v0wj93xwh21av10n8nxvdskacw5dxz";
|
2018-09-06 15:10:37 +02:00
|
|
|
};
|
|
|
|
|
2018-11-16 00:29:48 +01:00
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./libpath.patch;
|
|
|
|
env = "${buildEnv {
|
|
|
|
name = "wee-slack-env";
|
2019-09-04 18:13:50 +02:00
|
|
|
paths = with python3Packages; [ websocket_client six ];
|
|
|
|
}}/${python3Packages.python.sitePackages}";
|
2018-11-16 00:29:48 +01:00
|
|
|
})
|
2020-03-25 20:08:26 -07:00
|
|
|
./hardcode-json-file-path.patch
|
2018-11-16 00:29:48 +01:00
|
|
|
];
|
|
|
|
|
2020-03-25 20:08:26 -07:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace wee_slack.py --subst-var out
|
|
|
|
'';
|
|
|
|
|
2018-09-06 15:10:37 +02:00
|
|
|
passthru.scripts = [ "wee_slack.py" ];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/share
|
|
|
|
cp wee_slack.py $out/share/wee_slack.py
|
2020-03-25 20:08:26 -07:00
|
|
|
install -D -m 0444 weemoji.json $out/share/wee-slack/weemoji.json
|
2018-09-06 15:10:37 +02:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2020-03-31 21:11:51 -04:00
|
|
|
homepage = "https://github.com/wee-slack/wee-slack";
|
2018-09-06 15:10:37 +02:00
|
|
|
license = licenses.mit;
|
2019-10-19 21:40:04 +02:00
|
|
|
maintainers = with maintainers; [ willibutz ];
|
2018-09-06 15:10:37 +02:00
|
|
|
description = ''
|
|
|
|
A WeeChat plugin for Slack.com. Synchronizes read markers, provides typing notification, search, etc..
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
}
|