diff options
Diffstat (limited to 'fs/commands/fsrm.py')
-rw-r--r-- | fs/commands/fsrm.py | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/fs/commands/fsrm.py b/fs/commands/fsrm.py index 5e2bd09..8985e64 100644 --- a/fs/commands/fsrm.py +++ b/fs/commands/fsrm.py @@ -6,10 +6,10 @@ from fs.commands.runner import Command import sys class FSrm(Command): - + usage = """fsrm [OPTION]... [PATH] Remove a file or directory at PATH""" - + def get_optparse(self): optparse = super(FSrm, self).get_optparse() optparse.add_option('-f', '--force', dest='force', action='store_true', default=False, @@ -19,13 +19,13 @@ Remove a file or directory at PATH""" optparse.add_option('-r', '--recursive', dest='recursive', action='store_true', default=False, help='remove directories and their contents recursively') return optparse - + def do_run(self, options, args): - + interactive = options.interactive verbose = options.verbose - - for fs, path, is_dir in self.get_resources(args): + + for fs, path, is_dir in self.get_resources(args): if interactive: if is_dir: msg = "remove directory '%s'?" % path @@ -44,11 +44,11 @@ Remove a file or directory at PATH""" else: if verbose: self.output("removed '%s'\n" % path) - - -def run(): + + +def run(): return FSrm().run() - + if __name__ == "__main__": - sys.exit(run()) -
\ No newline at end of file + sys.exit(run()) + |