Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions fuse_rsync.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def list(self, path = '/'):
in a datetime object) and *filename* (The file's name).
"""
# See http://stackoverflow.com/questions/10323060/printing-file-permissions-like-ls-l-using-stat2-in-c for modes
RE_LINE = re.compile("^([ldcbps-]([r-][w-][x-]){3})\s+([0-9]+)\s+([0-9]{4}/[0-9]{2}/[0-9]{2} [0-9]{2}:[0-9]{2}:[0-9]{2}) (.*)$")
RE_LINE = re.compile("^([ldcbps-]([r-][w-][x-]){3})\s+([\d,]+)\s+([0-9]{4}/[0-9]{2}/[0-9]{2} [0-9]{2}:[0-9]{2}:[0-9]{2}) (.*)$")
remote_url = self._remote_url + path
try:
cmdline = ["rsync", "--list-only", remote_url]
Expand All @@ -86,7 +86,7 @@ def list(self, path = '/'):

listing.append({
"attrs": self._parse_attrs(match.group(1)),
"size": int(match.group(3)),
"size": int(match.group(3).replace(',','')),
"timestamp": datetime.datetime.strptime(match.group(4), "%Y/%m/%d %H:%M:%S"),
"filename": match.group(5)
})
Expand Down