Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pythonPackages.GitPython: set path to git executable #41844

Merged
merged 1 commit into from Jun 11, 2018

Conversation

flokli
Copy link
Contributor

@flokli flokli commented Jun 11, 2018

Motivation for this change

GitPython wants the git binary to be in $PATH, or some other environment variables being set to that executable. Patch path to git during initialization call to ${git}/bin/git.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@flokli flokli requested a review from FRidh as a code owner June 11, 2018 15:17
@flokli
Copy link
Contributor Author

flokli commented Jun 11, 2018

Note this effectively disables reading from GIT_PYTHON_GIT_EXECUTABLE.
Not sure if we want to keep that behaviour and write a patch instead that does both. Calling refresh() with a custom path is still possible, too.

@FRidh
Copy link
Member

FRidh commented Jun 11, 2018

@GrahamcOfBorg build pythonPackages.GitPython python3Packages.GitPython

@GrahamcOfBorg
Copy link

Success on x86_64-linux (full log)

Attempted: pythonPackages.GitPython, python3Packages.GitPython

Partial log (click to expand)

Requirement already satisfied: smmap2>=2.0.0 in /nix/store/yxfvshqpd51jraqxp9b4gm11wac58k2b-python3.6-smmap2-2.0.3/lib/python3.6/site-packages (from gitdb2>=2.0.0->GitPython==2.1.9) (2.0.3)
Installing collected packages: GitPython
Successfully installed GitPython-2.1.9
/build/GitPython-2.1.9
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/n0bqc7b4g74mps9cb87db8nnbhwlp08l-python3.6-GitPython-2.1.9
strip is /nix/store/21ymadblbmsbb2bk4q7gl4kjasp8zmgd-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/n0bqc7b4g74mps9cb87db8nnbhwlp08l-python3.6-GitPython-2.1.9/lib
patching script interpreter paths in /nix/store/n0bqc7b4g74mps9cb87db8nnbhwlp08l-python3.6-GitPython-2.1.9
checking for references to /build in /nix/store/n0bqc7b4g74mps9cb87db8nnbhwlp08l-python3.6-GitPython-2.1.9...

@GrahamcOfBorg
Copy link

Success on x86_64-darwin (full log)

Attempted: pythonPackages.GitPython, python3Packages.GitPython

Partial log (click to expand)

Processing ./GitPython-2.1.9-py2.py3-none-any.whl
Requirement already satisfied: gitdb2>=2.0.0 in /nix/store/h8g4q5xgm82fa87qcmx9rcwph7d3gd8m-python3.6-gitdb2-2.0.3/lib/python3.6/site-packages (from GitPython==2.1.9) (2.0.3)
Requirement already satisfied: smmap2>=2.0.0 in /nix/store/8jf1pgdx1bmxs04mc4scb80wqzk5v8qb-python3.6-smmap2-2.0.3/lib/python3.6/site-packages (from gitdb2>=2.0.0->GitPython==2.1.9) (2.0.3)
Installing collected packages: GitPython
Successfully installed GitPython-2.1.9
/private/tmp/nix-build-python3.6-GitPython-2.1.9.drv-0/GitPython-2.1.9
post-installation fixup
strip is /nix/store/yyak5sjv68n9vdgnkd2cb5djk1l9sqj5-cctools-binutils-darwin/bin/strip
stripping (with command strip and flags -S) in /nix/store/pzz462lvd48gsgf3qa17vpimjn4y23lp-python3.6-GitPython-2.1.9/lib
patching script interpreter paths in /nix/store/pzz462lvd48gsgf3qa17vpimjn4y23lp-python3.6-GitPython-2.1.9

@GrahamcOfBorg
Copy link

Success on aarch64-linux (full log)

Attempted: pythonPackages.GitPython, python3Packages.GitPython

Partial log (click to expand)

Successfully installed GitPython-2.1.9
/build/GitPython-2.1.9
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/5f00nvjrw88ryphpl5ivki0v5zipdrck-python3.6-GitPython-2.1.9
strip is /nix/store/qg2agrqkf240s656d207zqhipl0bc2id-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/5f00nvjrw88ryphpl5ivki0v5zipdrck-python3.6-GitPython-2.1.9/lib
patching script interpreter paths in /nix/store/5f00nvjrw88ryphpl5ivki0v5zipdrck-python3.6-GitPython-2.1.9
checking for references to /build in /nix/store/5f00nvjrw88ryphpl5ivki0v5zipdrck-python3.6-GitPython-2.1.9...
/nix/store/vrynn3ws0309xyl43gr0ppq8qk9vg89s-python2.7-GitPython-2.1.9
/nix/store/5f00nvjrw88ryphpl5ivki0v5zipdrck-python3.6-GitPython-2.1.9

@FRidh FRidh merged commit c16e457 into NixOS:master Jun 11, 2018
@flokli flokli deleted the gitpython-git branch June 11, 2018 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants