diff options
author | Orivej Desh <orivej@gmx.fr> | 2017-12-14 17:31:25 +0000 |
---|---|---|
committer | Orivej Desh <orivej@gmx.fr> | 2017-12-14 17:31:25 +0000 |
commit | 9f5b8aaec4a62e7866276c4754321c6627c06434 (patch) | |
tree | a37e8e275b993ab97b5022a78e1402706d8ab09f /pkgs/tools/misc/thefuck/default.nix | |
parent | 8a11e0d13376de31aa631be28f69771adf6e8e67 (diff) | |
download | nixpkgs-9f5b8aaec4a62e7866276c4754321c6627c06434.tar nixpkgs-9f5b8aaec4a62e7866276c4754321c6627c06434.tar.gz nixpkgs-9f5b8aaec4a62e7866276c4754321c6627c06434.tar.bz2 nixpkgs-9f5b8aaec4a62e7866276c4754321c6627c06434.tar.lz nixpkgs-9f5b8aaec4a62e7866276c4754321c6627c06434.tar.xz nixpkgs-9f5b8aaec4a62e7866276c4754321c6627c06434.tar.zst nixpkgs-9f5b8aaec4a62e7866276c4754321c6627c06434.zip |
thefuck: 3.18 -> 3.25
Fixes #32670
Diffstat (limited to 'pkgs/tools/misc/thefuck/default.nix')
-rw-r--r-- | pkgs/tools/misc/thefuck/default.nix | 38 |
1 files changed, 24 insertions, 14 deletions
diff --git a/pkgs/tools/misc/thefuck/default.nix b/pkgs/tools/misc/thefuck/default.nix index b399077bc5b..788529125da 100644 --- a/pkgs/tools/misc/thefuck/default.nix +++ b/pkgs/tools/misc/thefuck/default.nix @@ -1,22 +1,32 @@ -{ fetchurl, stdenv, pkgs, ... }: +{ stdenv, fetchFromGitHub, buildPythonApplication +, colorama, decorator, psutil, pyte, six +, pytest, pytest-mock +}: -pkgs.pythonPackages.buildPythonPackage rec { - name = "${pname}-${version}"; +buildPythonApplication rec { pname = "thefuck"; - version = "3.18"; + version = "3.25"; - src = fetchurl { - url = "https://github.com/nvbn/${pname}/archive/${version}.tar.gz"; - sha256 = "1xsvkqh89rgxq5w03mnlcfkn9y39nfwhb2pjabjspcc2mi2mq5y6"; + src = fetchFromGitHub { + owner = "nvbn"; + repo = "${pname}"; + rev = version; + sha256 = "090mg809aac932lgqmjxm4za53lg3bjprj562sp189k47xs4wijv"; }; - propagatedBuildInputs = with pkgs.pythonPackages; [ - psutil - colorama - six - decorator - pathlib2 - ]; + propagatedBuildInputs = [ colorama decorator psutil pyte six ]; + + checkInputs = [ pytest pytest-mock ]; + + checkPhase = '' + export HOME=$TMPDIR + export LANG=en_US.UTF-8 + export XDG_CACHE_HOME=$TMPDIR/cache + export XDG_CONFIG_HOME=$TMPDIR/config + py.test + ''; + + doCheck = false; # The above is only enough for tests to pass outside the sandbox. meta = with stdenv.lib; { homepage = https://github.com/nvbn/thefuck; |