comparison mercurial/commands.py @ 14551:68d814a3cefd

fileset: basic pattern and boolean support debugfileset can now generate file lists for things like: "* and not hg*"
author Matt Mackall <mpm@selenic.com>
date Wed, 08 Jun 2011 13:44:41 -0500
parents cd1a01550ca2
children d976542986d2
comparison
equal deleted inserted replaced
14550:2425a3536396 14551:68d814a3cefd
1601 def debugfileset(ui, repo, expr): 1601 def debugfileset(ui, repo, expr):
1602 '''parse and apply a fileset specification''' 1602 '''parse and apply a fileset specification'''
1603 if ui.verbose: 1603 if ui.verbose:
1604 tree = fileset.parse(expr)[0] 1604 tree = fileset.parse(expr)[0]
1605 ui.note(tree, "\n") 1605 ui.note(tree, "\n")
1606 matcher = lambda x: scmutil.match(repo, x, default='glob')
1607
1608 for f in fileset.getfileset(repo[None], matcher, expr):
1609 ui.write("%s\n" % f)
1606 1610
1607 @command('debugfsinfo', [], _('[PATH]')) 1611 @command('debugfsinfo', [], _('[PATH]'))
1608 def debugfsinfo(ui, path = "."): 1612 def debugfsinfo(ui, path = "."):
1609 """show information detected about current filesystem""" 1613 """show information detected about current filesystem"""
1610 util.writefile('.debugfsinfo', '') 1614 util.writefile('.debugfsinfo', '')