2017-03-03 01:44:17 +00:00
|
|
|
{ stdenv, fetchFromGitHub, coreutils
|
|
|
|
, python3, python3Packages, substituteAll }:
|
2014-12-23 07:35:26 +00:00
|
|
|
|
2014-12-23 10:30:56 +00:00
|
|
|
assert stdenv.isLinux;
|
|
|
|
|
2017-03-03 01:44:17 +00:00
|
|
|
python3Packages.buildPythonApplication rec {
|
2014-12-23 07:35:26 +00:00
|
|
|
name = "trash-cli-${version}";
|
2017-03-03 01:44:17 +00:00
|
|
|
version = "0.17.1.14";
|
2014-12-23 07:35:26 +00:00
|
|
|
namePrefix = "";
|
|
|
|
|
2017-03-03 01:44:17 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "andreafrancia";
|
|
|
|
repo = "trash-cli";
|
|
|
|
rev = "${version}";
|
|
|
|
sha256 = "1bqazna223ibqjwbc1wfvfnspfyrvjy8347qlrgv4cpng72n7gfi";
|
2014-12-23 07:35:26 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./nix-paths.patch;
|
|
|
|
df = "${coreutils}/bin/df";
|
2015-04-26 18:54:51 +01:00
|
|
|
libc = "${stdenv.cc.libc.out}/lib/libc.so.6";
|
2014-12-23 07:35:26 +00:00
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2017-03-03 01:44:17 +00:00
|
|
|
buildInputs = with python3Packages; [ nose mock ];
|
2014-12-23 07:35:26 +00:00
|
|
|
|
|
|
|
checkPhase = "nosetests";
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = https://github.com/andreafrancia/trash-cli;
|
|
|
|
description = "Command line tool for the desktop trash can";
|
2016-02-10 13:59:36 +00:00
|
|
|
maintainers = [ maintainers.rycee ];
|
2016-05-22 15:06:06 +01:00
|
|
|
platforms = platforms.all;
|
2014-12-23 07:35:26 +00:00
|
|
|
license = licenses.gpl2;
|
|
|
|
};
|
|
|
|
}
|