diff options
author | Peter Hoeg <peter@speartail.com> | 2017-01-06 18:56:26 +0800 |
---|---|---|
committer | Peter Hoeg <peter@speartail.com> | 2017-01-06 18:56:26 +0800 |
commit | 98c9db00d8576f4ebe8e13ea857bd679118d4f06 (patch) | |
tree | 84deef1cbf2ad932869d8510d0781da25c8052e6 /pkgs/applications/version-management | |
parent | 59dbcefaa74b940f9b7490c034dc4ff885fa2627 (diff) |
git-up: not a python package
1. git-up is a python package as such but an application, so move it out of python-packages.nix 2. get rid of the tests (we've already run the tests)
Diffstat (limited to 'pkgs/applications/version-management')
-rw-r--r-- | pkgs/applications/version-management/git-up/default.nix | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/pkgs/applications/version-management/git-up/default.nix b/pkgs/applications/version-management/git-up/default.nix new file mode 100644 index 0000000000000..c93ee92446631 --- /dev/null +++ b/pkgs/applications/version-management/git-up/default.nix @@ -0,0 +1,35 @@ +{ stdenv, fetchurl, python2Packages, git }: + +python2Packages.buildPythonApplication rec { + version = "1.4.2"; + name = "git-up-${version}"; + + src = fetchurl { + url = "mirror://pypi/g/git-up/${name}.zip"; + sha256 = "121ia5gyjy7js6fbsx9z98j2qpq7rzwpsj8gnfvsbz2d69g0vl7q"; + }; + + buildInputs = [ git ] ++ (with python2Packages; [ nose ]); + propagatedBuildInputs = with python2Packages; [ click colorama docopt GitPython six termcolor ]; + + # 1. git fails to run as it cannot detect the email address, so we set it + # 2. $HOME is by default not a valid dir, so we have to set that too + # https://github.com/NixOS/nixpkgs/issues/12591 + preCheck = '' + export HOME=$TMPDIR + git config --global user.email "nobody@example.com" + git config --global user.name "Nobody" + ''; + + postInstall = '' + rm -r $out/${python2Packages.python.sitePackages}/PyGitUp/tests + ''; + + meta = with stdenv.lib; { + homepage = http://github.com/msiemens/PyGitUp; + description = "A git pull replacement that rebases all local branches when pulling."; + license = licenses.mit; + maintainers = with maintainers; [ peterhoeg ]; + platforms = platforms.all; + }; +} |