1{ stdenv
2, lib
3, buildPythonPackage
4, fetchFromGitHub
5, pytest
6, configparser
7}:
8
9buildPythonPackage rec {
10 pname = "Send2Trash";
11 version = "1.4.2";
12
13 src = fetchFromGitHub {
14 owner = "hsoft";
15 repo = "send2trash";
16 rev = version;
17 sha256 = "1w502i5h8xaqf03g6h95h4vs1wqfv6kg925dn63phrwmg1hfz2xx";
18 };
19
20 doCheck = !stdenv.isDarwin;
21 checkPhase = "HOME=. py.test";
22 checkInputs = [ pytest configparser ];
23
24 meta = with lib; {
25 description = "Send file to trash natively under macOS, Windows and Linux";
26 homepage = https://github.com/hsoft/send2trash;
27 license = licenses.bsd3;
28 };
29}