comparison hg @ 106:e8d4bbf4c9e2

Don't diff unknown files Fix syntax error from log date
author mpm@selenic.com
date Wed, 18 May 2005 17:37:49 -0800
parents 6eeb50050486
children 707a7481a861
comparison
equal deleted inserted replaced
105:6eeb50050486 106:e8d4bbf4c9e2
70 change = repo.changelog.read(node1) 70 change = repo.changelog.read(node1)
71 mmap = repo.manifest.read(change[0]) 71 mmap = repo.manifest.read(change[0])
72 date1 = date(change) 72 date1 = date(change)
73 73
74 if files: 74 if files:
75 (c, a, d) = map(lambda x: filterfiles(x, files), (c, a, d)) 75 c = filterfiles(c, files)
76 d = filterfiles(d, files)
76 77
77 for f in c: 78 for f in c:
78 to = repo.file(f).read(mmap[f]) 79 to = repo.file(f).read(mmap[f])
79 tn = read(f)
80 sys.stdout.write(mdiff.unidiff(to, date1, tn, date2, f))
81 for f in a:
82 to = ""
83 tn = read(f) 80 tn = read(f)
84 sys.stdout.write(mdiff.unidiff(to, date1, tn, date2, f)) 81 sys.stdout.write(mdiff.unidiff(to, date1, tn, date2, f))
85 for f in d: 82 for f in d:
86 to = repo.file(f).read(mmap[f]) 83 to = repo.file(f).read(mmap[f])
87 tn = "" 84 tn = ""
320 print "parents: %4d:%s" % (i1, h1) 317 print "parents: %4d:%s" % (i1, h1)
321 if i2: print " %4d:%s" % (i2, h2) 318 if i2: print " %4d:%s" % (i2, h2)
322 changes = repo.changelog.read(repo.changelog.node(cr)) 319 changes = repo.changelog.read(repo.changelog.node(cr))
323 print "user: %s" % changes[1] 320 print "user: %s" % changes[1]
324 print "date: %s" % time.asctime( 321 print "date: %s" % time.asctime(
325 time.localtime(float(changes[2].split(' ')[0])))) 322 time.localtime(float(changes[2].split(' ')[0])))
326 print "description:" 323 print "description:"
327 print changes[4] 324 print changes[4]
328 print 325 print
329 elif len(args) > 1: 326 elif len(args) > 1:
330 print "too many args" 327 print "too many args"