freemyipod r350 - Code Review

Jump to: navigation, search
Repository:freemyipod
Revision:r349‎ | r350 | r351 >
Date:01:44, 20 December 2010
Author:theseven
Status:new
Tags:
Comment:
embios.py: Add "rename" function
Modified paths:
  • /embios/trunk/tools/embios.py (modified) (history)

Diff [purge]

Index: embios/trunk/tools/embios.py
@@ -855,6 +855,16 @@
856856 self.logger.info(" done\n")
857857
858858 @command
 859+ def rename(self, oldname, newname):
 860+ """
 861+ Removes a file
 862+ """
 863+ self.embios.lib.dev.timeout = 30000
 864+ self.logger.info("Renaming " + oldname + " to " + newname + "...")
 865+ self.embios.file_rename(oldname, newname)
 866+ self.logger.info(" done\n")
 867+
 868+ @command
859869 def get(self, buffer, buffsize, remotename, localname):
860870 """
861871 Downloads a file