Skip to content

Commit 794b3c2

Browse files
committed
Improve git clone handling
- Use environment variable for LFS - Update version to 0.7.4
1 parent 4c4928e commit 794b3c2

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

pycsghub/repository.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,11 +225,13 @@ def git_clone(
225225
repo_url: str
226226
) -> subprocess.CompletedProcess:
227227
try:
228+
env = os.environ.copy()
229+
env.update({"GIT_LFS_SKIP_SMUDGE": "1"})
228230
result = self.run_subprocess(
229231
command=f"git clone -b {branch_name} {repo_url}",
230232
folder=self.work_dir,
231233
check=True,
232-
env={"GIT_LFS_SKIP_SMUDGE": "1"}
234+
env=env
233235
).stdout.strip()
234236
except subprocess.CalledProcessError as exc:
235237
raise EnvironmentError(exc.stderr)

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
setup(
77
name='csghub-sdk',
8-
version='0.7.3',
8+
version='0.7.4',
99
author="opencsg",
1010
author_email="contact@opencsg.com",
1111
long_description=long_description,

0 commit comments

Comments
 (0)