uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
|
|
@ -0,0 +1,48 @@
|
|||
{ lib, stdenv, substituteAll, buildEnv, fetchFromGitHub, python3Packages }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "wee-slack";
|
||||
version = "2.8.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
repo = "wee-slack";
|
||||
owner = "wee-slack";
|
||||
rev = "v${version}";
|
||||
sha256 = "0xfklr0gsc9jgxfyrrb2j756lclz9g8imcb0pk0xgyj8mhsw23zk";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(substituteAll {
|
||||
src = ./libpath.patch;
|
||||
env = "${buildEnv {
|
||||
name = "wee-slack-env";
|
||||
paths = with python3Packages; [
|
||||
websocket-client
|
||||
six
|
||||
];
|
||||
}}/${python3Packages.python.sitePackages}";
|
||||
})
|
||||
./load_weemoji_path.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace wee_slack.py --subst-var out
|
||||
'';
|
||||
|
||||
passthru.scripts = [ "wee_slack.py" ];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/share
|
||||
cp wee_slack.py $out/share/wee_slack.py
|
||||
install -D -m 0444 weemoji.json $out/share/wee-slack/weemoji.json
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/wee-slack/wee-slack";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ willibutz ];
|
||||
description = ''
|
||||
A WeeChat plugin for Slack.com. Synchronizes read markers, provides typing notification, search, etc..
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
diff --git a/wee_slack.py b/wee_slack.py
|
||||
index e4716b4..f673b7c 100644
|
||||
--- a/wee_slack.py
|
||||
+++ b/wee_slack.py
|
||||
@@ -31,6 +31,8 @@ import string
|
||||
# See https://github.com/numpy/numpy/issues/11925
|
||||
sys.modules["numpy"] = None
|
||||
|
||||
+sys.path.append('@env@')
|
||||
+
|
||||
from websocket import ( # noqa: E402
|
||||
ABNF,
|
||||
create_connection,
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
diff --git a/wee_slack.py b/wee_slack.py
|
||||
index e4716b4..ffd122d 100644
|
||||
--- a/wee_slack.py
|
||||
+++ b/wee_slack.py
|
||||
@@ -6092,19 +6092,7 @@ def create_slack_debug_buffer():
|
||||
|
||||
def load_emoji():
|
||||
try:
|
||||
- weechat_dir = w.info_get("weechat_data_dir", "") or w.info_get(
|
||||
- "weechat_dir", ""
|
||||
- )
|
||||
- weechat_sharedir = w.info_get("weechat_sharedir", "")
|
||||
- local_weemoji, global_weemoji = (
|
||||
- "{}/weemoji.json".format(path) for path in (weechat_dir, weechat_sharedir)
|
||||
- )
|
||||
- path = (
|
||||
- global_weemoji
|
||||
- if os.path.exists(global_weemoji) and not os.path.exists(local_weemoji)
|
||||
- else local_weemoji
|
||||
- )
|
||||
- with open(path, "r") as ef:
|
||||
+ with open("@out@/share/wee-slack/weemoji.json", "r") as ef:
|
||||
emojis = json.loads(ef.read())
|
||||
if "emoji" in emojis:
|
||||
print_error(
|
||||
Loading…
Add table
Add a link
Reference in a new issue