PolyRename Documentation¶
Welcome to the documentation for PolyRename, a cross-platform, bulk-file rename tool.
Contents¶
Concepts¶
Transformation¶
Transformations are small, atomic operations that modify a filename in a simple way. For example, the Suffix transformation appends text to the end of a file’s name, while the Replace Extension transformation replaces the selected files’ extension with a specified extension.
Pipeline¶
The pipeline is an ordered sequence of transformations which are applied to a file sequence. The first transformation is applied, then the second is applied to the output of the first, and so on. This allows the user to construct advanced rename operations out of the simple transformations.
Usage¶
This section contains information on how to use PolyRename. Most users will want to view the GUI documentation.
GUI¶
The user interface of PolyRename was designed to be simple to use, unlike many other bulk-file rename tools. It’s GUI interface is divided into 4 quadrants.

At the top right is the File Picker. The file picker is used to select files on the user’s computer, and to visualize which files (and in what order) are currently selected.

At the bottom left is the Transformation Library. The transformation library is automatically populated with the available transformations. From this interface, the user can select a transformation to begin configuring that transformation.

At the bottom right is the Transformation Config. This interface allows the user to configure the selected transformation before appending the configured transformation to the pipeline. This interface performs error checking to ensure that the user has entered a value for all required fields, and that all entered values are of the expected datatype.

Finally, at the top left is the Pipeline Editor. The pipeline editor shows you the current state of your pipeline, and allows you to modify your pipeline. Modification actions include moving a configured transformation up or down in the pipeline’s sequence or deleting a configured transformation from the pipeline. Finally, this interface allows the user to apply a pipeline to their selected file sequence. Upon pressing the “Apply Pipeline” button, a preview of the resulting file sequence modifications is shown.


For Developers¶
This section contains information on how PolyRename is structured, along with how to extend PolyRename through it’s Plugin system.
Git¶
Plugin¶
Transformations can be user-created an added to PolyRename. To do this, place a .py file in the polyrename/transformation/ package, and modify polyrename/transformation/__init__.py such that your newly created transformation is imported.
Transformations must do the following to be considered valid:
Define a class which inherits from Transformation
Define a static variable schema which conforms to the defined specification
Define a __init__ method which takes an argument for each option defined in the schema in the same order as the schema defines it
Define a resolve method which takes a file sequence as an argument, and returns a file sequence
Define a __repr__ method. This will be used to display the configured transformation in the Pipeline Editor
See the existing transformations for reference when creating your own.