~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/builtins.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2006-04-07 04:31:15 UTC
  • mfrom: (1626.1.2 bzr.mbp.integration)
  • Revision ID: pqm@pqm.ubuntu.com-20060407043115-653eafe5cfa29760
(mbp) better log help message

Show diffs side-by-side

added added

removed removed

Lines of Context:
1053
1053
 
1054
1054
 
1055
1055
class cmd_log(Command):
1056
 
    """Show log of this branch.
 
1056
    """Show log of a branch, file, or directory.
 
1057
 
 
1058
    By default show the log of the branch containing the working directory.
1057
1059
 
1058
1060
    To request a range of logs, you can use the command -r begin..end
1059
1061
    -r revision requests a specific revision, -r ..end or -r begin.. are
1060
1062
    also valid.
 
1063
 
 
1064
    examples:
 
1065
        bzr log
 
1066
        bzr log foo.c
 
1067
        bzr log -r -10.. http://server/branch
1061
1068
    """
1062
1069
 
1063
1070
    # TODO: Make --revision support uuid: and hash: [future tag:] notation.
1064
1071
 
1065
 
    takes_args = ['filename?']
 
1072
    takes_args = ['location?']
1066
1073
    takes_options = [Option('forward', 
1067
1074
                            help='show from oldest to newest'),
1068
 
                     'timezone', 'verbose', 
 
1075
                     'timezone', 
 
1076
                     Option('verbose', 
 
1077
                             help='show files changed in each revision'),
1069
1078
                     'show-ids', 'revision',
1070
1079
                     'log-format',
1071
1080
                     'line', 'long', 
1075
1084
                     'short',
1076
1085
                     ]
1077
1086
    @display_command
1078
 
    def run(self, filename=None, timezone='original',
 
1087
    def run(self, location=None, timezone='original',
1079
1088
            verbose=False,
1080
1089
            show_ids=False,
1081
1090
            forward=False,
1093
1102
        
1094
1103
        # log everything
1095
1104
        file_id = None
1096
 
        if filename:
 
1105
        if location:
1097
1106
            # find the file id to log:
1098
1107
 
1099
 
            dir, fp = bzrdir.BzrDir.open_containing(filename)
 
1108
            dir, fp = bzrdir.BzrDir.open_containing(location)
1100
1109
            b = dir.open_branch()
1101
1110
            if fp != '':
1102
1111
                try: