summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJed Brown <jed@jedbrown.org>2017-01-31 09:42:29 -0700
committerJed Brown <jed@jedbrown.org>2017-01-31 09:42:29 -0700
commit83ab2b75a001c7833b969237505803d8d235cb84 (patch)
tree2e7f89269b11c688bcb8fd78dabc191e79b43ef3
parentd5b388cbe2259efe1532783af08d428ba0fada3e (diff)
downloadgit-fat-83ab2b75a001c7833b969237505803d8d235cb84.tar.gz
Fix sorted syntax for 'git fat find' with Python 2/3 [closes #74]
Reported-by: Isuru Fernando
-rwxr-xr-xgit-fat2
1 files changed, 1 insertions, 1 deletions
diff --git a/git-fat b/git-fat
index dd6af72..3b9fc16 100755
--- a/git-fat
+++ b/git-fat
@@ -537,7 +537,7 @@ class GitFat(object):
time1 = time.time()
self.verbose('Found %d paths in %.3f s' % (len(pathsizes), time1-time0))
maxlen = max(map(len,pathsizes)) if pathsizes else 0
- for path, sizes in sorted(pathsizes.items(), key=lambda p,s: max(s), reverse=True):
+ for path, sizes in sorted(pathsizes.items(), key=lambda ps: max(ps[1]), reverse=True):
print('%-*s filter=fat -text # %10d %d' % (maxlen, path,max(sizes),len(sizes)))
revlist.wait()
difftree.wait()