Skip to content

Commit d6fed71

Browse files
committed
XX
Signed-off-by: Matthew Ballance <matt.ballance@gmail.com>
1 parent 8226807 commit d6fed71

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

src/ivpm/package_file.py

+8-5
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,15 @@ def update(self, update_info : UpdateInfo) -> ProjInfo:
3939
pkg_dir = os.path.join(update_info.deps_dir, self.name)
4040
self.path = pkg_dir.replace("\\", "/")
4141

42-
# Install (unpack) the file
42+
if not os.path.isdir(pkg_dir):
43+
# Install (unpack) the file
44+
if self.unpack:
45+
self._install(self.url, pkg_dir)
4346

44-
# Now, check the package for dependencies
45-
info : ProjInfo = ProjectInfoReader(pkg_dir).read()
46-
47-
return info
47+
if os.path.isdir(pkg_dir):
48+
return ProjectInfoReader(pkg_dir).read()
49+
else:
50+
return None
4851

4952
def _install(self, pkg_src, pkg_path):
5053
if self.src_type in (".tar.gz", ".tar.xz", ".tar.bz2"):

0 commit comments

Comments
 (0)