aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/virtual_sdcard.py
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2019-02-08 11:48:53 -0500
committerKevin O'Connor <kevin@koconnor.net>2019-02-08 11:48:53 -0500
commitf1c804907c4470160472f6407c58f0c9e47bcebb (patch)
tree736e283cc084c9644614353c7d5b6c860781ffe6 /klippy/extras/virtual_sdcard.py
parent9766d62ad306b179b0ef606d1a2df1dde9b2d47a (diff)
downloadkutter-f1c804907c4470160472f6407c58f0c9e47bcebb.tar.gz
kutter-f1c804907c4470160472f6407c58f0c9e47bcebb.tar.xz
kutter-f1c804907c4470160472f6407c58f0c9e47bcebb.zip
virtual_sdcard: Don't list files starting with a '.'
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/extras/virtual_sdcard.py')
-rw-r--r--klippy/extras/virtual_sdcard.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/klippy/extras/virtual_sdcard.py b/klippy/extras/virtual_sdcard.py
index 84e80e9f..91bd31a9 100644
--- a/klippy/extras/virtual_sdcard.py
+++ b/klippy/extras/virtual_sdcard.py
@@ -48,7 +48,8 @@ class VirtualSD:
try:
filenames = os.listdir(self.sdcard_dirname)
return [(fname, os.path.getsize(os.path.join(dname, fname)))
- for fname in filenames]
+ for fname in filenames
+ if not fname.startswith('.')]
except:
logging.exception("virtual_sdcard get_file_list")
raise self.gcode.error("Unable to get file list")