Skip to content

Commit

Permalink
add
Browse files Browse the repository at this point in the history
  • Loading branch information
farfun committed Dec 26, 2024
1 parent 82eb8a1 commit 594c165
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 34 deletions.
18 changes: 3 additions & 15 deletions logs/all.log
Original file line number Diff line number Diff line change
@@ -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
18 changes: 3 additions & 15 deletions logs/funbuild.log
Original file line number Diff line number Diff line change
@@ -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
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "fundrive"
version = "1.2.86"
version = "1.2.87"
description = "fundrive"
readme = "README.md"
requires-python = ">=3.8"
Expand Down
6 changes: 4 additions & 2 deletions src/fundrive/drives/baidu/drive.py
Original file line number Diff line number Diff line change
Expand Up @@ -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 = {
Expand All @@ -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,
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 594c165

Please sign in to comment.