mirror of
https://github.com/git/git.git
synced 2026-01-19 15:09:01 +00:00
Merge branch 'sr/remote-helper-export' into next
* sr/remote-helper-export: Makefile: Simplify handling of python scripts Conflicts: Makefile
This commit is contained in:
9
Makefile
9
Makefile
@@ -1629,13 +1629,8 @@ $(patsubst %.py,%,$(SCRIPT_PYTHON)): % : %.py
|
||||
INSTLIBDIR=`MAKEFLAGS= $(MAKE) -C git_remote_helpers -s \
|
||||
--no-print-directory prefix='$(prefix_SQ)' DESTDIR='$(DESTDIR_SQ)' \
|
||||
instlibdir` && \
|
||||
sed -e '1{' \
|
||||
-e ' s|#!.*python|#!$(PYTHON_PATH_SQ)|' \
|
||||
-e '}' \
|
||||
-e 's|^import sys.*|&; \\\
|
||||
import os; \\\
|
||||
sys.path.insert(0, os.getenv("GITPYTHONLIB",\
|
||||
"@@INSTLIBDIR@@"));|' \
|
||||
sed -e '1s|#!.*python|#!$(PYTHON_PATH_SQ)|' \
|
||||
-e 's|\(os\.getenv("GITPYTHONLIB"\)[^)]*)|\1,"@@INSTLIBDIR@@")|' \
|
||||
-e 's|@@INSTLIBDIR@@|'"$$INSTLIBDIR"'|g' \
|
||||
$@.py >$@+ && \
|
||||
chmod +x $@+ && \
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
|
||||
import hashlib
|
||||
import sys
|
||||
import os
|
||||
sys.path.insert(0, os.getenv("GITPYTHONLIB","."))
|
||||
|
||||
from git_remote_helpers.util import die, debug, warn
|
||||
from git_remote_helpers.git.repo import GitRepo
|
||||
|
||||
Reference in New Issue
Block a user