diff --git a/logs/all.log b/logs/all.log index 4f101d0..3cf0030 100644 --- a/logs/all.log +++ b/logs/all.log @@ -1,15 +1,3 @@ -2024-12-23 20:51:38.197 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 20:51:38.202 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 20:51:46.817 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:00:25.114 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:00:25.114 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:00:32.553 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:04:06.011 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:04:06.012 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:04:14.408 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:05:39.630 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:05:39.630 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:05:47.161 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:06:37.305 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:06:37.306 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:06:43.853 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push +2024-12-26 16:52:47.994 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build +2024-12-26 16:52:48.001 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull +2024-12-26 16:52:57.169 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push diff --git a/logs/funbuild.log b/logs/funbuild.log index 4f101d0..3cf0030 100644 --- a/logs/funbuild.log +++ b/logs/funbuild.log @@ -1,15 +1,3 @@ -2024-12-23 20:51:38.197 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 20:51:38.202 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 20:51:46.817 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:00:25.114 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:00:25.114 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:00:32.553 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:04:06.011 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:04:06.012 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:04:14.408 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:05:39.630 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:05:39.630 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:05:47.161 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push -2024-12-23 21:06:37.305 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build -2024-12-23 21:06:37.306 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull -2024-12-23 21:06:43.853 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push +2024-12-26 16:52:47.994 |INFO | funbuild.core.core : core: 86 | funbuild | - fundrive build +2024-12-26 16:52:48.001 |INFO | funbuild.core.core : core: 74 | funbuild | - fundrive pull +2024-12-26 16:52:57.169 |INFO | funbuild.core.core : core: 78 | funbuild | - fundrive push diff --git a/pyproject.toml b/pyproject.toml index 4bbd6b0..d1657b4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "fundrive" -version = "1.2.86" +version = "1.2.87" description = "fundrive" readme = "README.md" requires-python = ">=3.8" diff --git a/src/fundrive/drives/baidu/drive.py b/src/fundrive/drives/baidu/drive.py index 6cfc8c2..485a4ea 100644 --- a/src/fundrive/drives/baidu/drive.py +++ b/src/fundrive/drives/baidu/drive.py @@ -58,7 +58,9 @@ def get_file_list(self, fid, *args, **kwargs) -> List[DriveFile]: def get_dir_list(self, fid, *args, **kwargs) -> List[DriveFile]: return [convert(file) for file in self.drive.list(fid) if file.is_dir] - def download_file(self, fid, local_dir, overwrite=False, *args, **kwargs) -> bool: + def download_file( + self, fid, local_dir, filename=None, overwrite=False, *args, **kwargs + ) -> bool: link = self.drive.download_link(fid) headers = { @@ -69,7 +71,7 @@ def download_file(self, fid, local_dir, overwrite=False, *args, **kwargs) -> boo try: download( link, - filepath=f"{local_dir}/{os.path.basename(fid)}", + filepath=f"{local_dir}/{filename or os.path.basename(fid)}", headers=headers, overwrite=overwrite, *args, diff --git a/uv.lock b/uv.lock index 35df24a..483a8e9 100644 --- a/uv.lock +++ b/uv.lock @@ -451,7 +451,7 @@ wheels = [ [[package]] name = "fundrive" -version = "1.2.86" +version = "1.2.87" source = { virtual = "." } dependencies = [ { name = "funget" },