~abentley/bzrtools/bzrtools.dev

« back to all changes in this revision

Viewing changes to __init__.py

  • Committer: Adeodato Simó
  • Date: 2006-07-12 18:17:03 UTC
  • mto: This revision was merged to the branch mainline in revision 416.
  • Revision ID: dato@net.com.org.es-20060712181703-af9e1c81c08d3af3
Make clean-tree --detritus or --ignored not delete also unknown files,
and add --unknown, noting it's the default option.

Show diffs side-by-side

added added

removed removed

Lines of Context:
34
34
                     Option('detritus', help='delete conflict files merge'
35
35
                            ' backups, and failed selftest dirs.  (*.THIS, '
36
36
                            '*.BASE, *.OTHER, *~, *.tmp)'), 
 
37
                     Option('unknown', help='delete files unknown to bzr.  (default)'),
37
38
                     Option('dry-run', help='show files to delete instead of'
38
39
                            ' deleting them.')]
39
 
    def run(self, ignored=False, detritus=False, dry_run=False):
 
40
    def run(self, unknown=False, ignored=False, detritus=False, dry_run=False):
40
41
        from clean_tree import clean_tree
41
 
        clean_tree('.', ignored=ignored, detritus=detritus, dry_run=dry_run)
 
42
        if not (unknown or ignored or detritus):
 
43
            unknown = True
 
44
        clean_tree('.', unknown=unknown, ignored=ignored, detritus=detritus, dry_run=dry_run)
42
45
 
43
46
class cmd_graph_ancestry(bzrlib.commands.Command):
44
47
    """Produce ancestry graphs using dot.