rope.contrib.fixmodnames

Fix the name of modules

This module is useful when you want to rename many of the modules in your project. That can happen specially when you want to change their naming style.

For instance:

fixer = FixModuleNames(project)
changes = fixer.get_changes(fixer=str.lower)
project.do(changes)

Here it renames all modules and packages to use lower-cased chars. You can tell it to use any other style by using the fixer argument.

Classes

FixModuleNames

Module Contents

class rope.contrib.fixmodnames.FixModuleNames(project)
project
get_changes(fixer=str.lower, task_handle=taskhandle.DEFAULT_TASK_HANDLE)

Fix module names

fixer is a function that takes and returns a str. Given the name of a module, it should return the fixed name.