~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/commands.py

  • Committer: Martin Pool
  • Date: 2005-05-06 03:45:17 UTC
  • Revision ID: mbp@sourcefrog.net-20050506034517-8f4f4909d65199a3
- fix relpath and add tests

Show diffs side-by-side

added added

removed removed

Lines of Context:
176
176
 
177
177
class cmd_relpath(Command):
178
178
    """Show path of a file relative to root"""
179
 
    takes_args = ('filename')
 
179
    takes_args = ['filename']
180
180
    
181
 
    def run(self):
182
 
        print Branch(self.args['filename']).relpath(filename)
 
181
    def run(self, filename):
 
182
        print Branch(filename).relpath(filename)
183
183
 
184
184
 
185
185