aboutsummaryrefslogtreecommitdiffstats
path: root/python/ice.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/ice.py')
-rw-r--r--python/ice.py7
1 files changed, 1 insertions, 6 deletions
diff --git a/python/ice.py b/python/ice.py
index af3fd3db..0d36c5fb 100644
--- a/python/ice.py
+++ b/python/ice.py
@@ -9,12 +9,7 @@ from serenitas.utils.remote import SftpClient
def download_files():
sftp = SftpClient.from_creds("ice")
dst = DAILY_DIR / "ICE_reports"
- import stat
-
- for f in sftp.client.listdir_attr("/"):
- local_file = dst / f.filename
- if (not local_file.exists()) and (not stat.S_ISDIR(f.st_mode)):
- sftp.client.get(f"//{f.filename}", localpath=local_file)
+ sftp.download_files("/", dst)
if __name__ == "__main__":