Skip to content

Commit ab7c322

Browse files
committed
fix(externals): init external in dev mode only
Previously it would always adjust your system path, which is bad behaviour.
1 parent 1fd07a0 commit ab7c322

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

git/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@
1515
#{ Initialization
1616
def _init_externals():
1717
"""Initialize external projects by putting them into the path"""
18-
sys.path.append(os.path.join(os.path.dirname(__file__), 'ext', 'gitdb'))
18+
if __version__ == 'git':
19+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), 'ext', 'gitdb'))
1920

2021
try:
2122
import gitdb

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy