Contribute to beta tools.¶
Get the code.¶
This guide is for developers who want to contribute to Conductor client packages.
Clone the repos you want to work on and checkout the beta branches.
git clone [email protected]:AtomicConductor/conductor-core.git --branch beta git clone [email protected]:AtomicConductor/conductor-maya.git --branch beta git clone [email protected]:AtomicConductor/conductor-c4d.git --branch beta git clone [email protected]:AtomicConductor/conductor-clarisse.git --branch beta
If you want to create a new submitter, we recommend you download and refer to one of the above plugins as a template.
Use the Python Imaging Library (Pillow) to generate icons.
pip install pillow
To ensure the installation flow works, use Pip with the
target option to build the packages from their working directories, and install into the default installation directory.
cd conductor-maya pip install --upgrade -r requirements.txt --target=$HOME/Conductor
To tell Maya about the plugin, either run the post install script.
OR - append the
conductor.mod location to the
You can now run Maya and you'll find the Conductor plugin in the Plugin Manager.
Cinema 4d setup.¶
Cinema 4d setup is similar to Maya.
cd conductor-c4d pip install --upgrade -r requirements.txt --target=$HOME/Conductor
In Cinema 4d go to Edit->Preferences->Plugins and browse for
cioc4d in the installation directory. By default, this will be:
As mentioned, Conductor Core is installed automatically when you install any of its dependents. If you want to install Core only, the process is similar, but rather than a requirements file, you can use a dot
. to represent the current directory.
cd conductor-core pip install --upgrade . --target=$HOME/Conductor
The Python packages
ciocore, and any dependencies are now installed in
~/Conductor. However, since the
target option was used, no entries were added to system Python paths. The goal is to set Python paths at the moment they are needed.
When you start Maya, the module file
conductor.mod sets the PYTHONPATH to
~/Conductor to make the packages available in the Maya session. Example
+ conductor 0.1.27 . PYTHONPATH+:=../
To use the conductor shell command, type
~/Conductor/bin/conductor. The Core python package is added to the modules path dynamically like so:
CIO_DIR = os.path.dirname(os.path.dirname(__file__)) sys.path.insert(0, CIO_DIR)
To use the Python API from a shell or somewhere else, you can set the
~/Conductor or install
ciocore without the target option and let pip add it to the system or virtualenv site-packages.
In order to allow intelli-sense or autocomplete to work in your IDE, you can set the PYTHONPATH to point to the local repos for the development scope. Example:
You shouldn't have these set in the environment where you run the built packages as they may conflict. Either setup separate environments or set the PYTHONPATH as you open the IDE.
I use this:
". ~/.virtualenvs/cmc/bin/activate && \ cd $HOME/dev/conductor/conductor-maya && \ pip install --upgrade -r requirements.txt --target=$HOME/Conductor && python $HOME/Conductor/ciomaya/post_install.py",
It activates the virtualenv for building (where Pillow is installed), then runs pip install from the working directory. To be sure of a clean install, you can add the
--force-reinstall flag. It also runs the
post_install script so that the mod file has the correct version. You'll then need to restart Maya.
For simplicity and consistency, packages have a plain text VERSION file at the root of the repo. It contains one line which is the version. The Companion App expects the VERSION file to be available to show the package on the plugins page.
Both the Maya and C4d build phases have a function to generate icons in various sizes depending on their intended use.
For Maya nodes, you can put images of any size in the images/nodeicons folder. You must name them the same as the node name. At build time, it generates two icons, one at 18px square with the prefix
out_ for display in the outliner, and one 36px, for display in other panels, such as the node editor.
Fixtures are cached versions of data on disk to speed up development. They replace the following endpoints with JSON files.
To use fixures, set the environment variable
CIO_FIXTURES_DIR to the location of the JSON files. In addition, set the
try_cache keyword to True on calls to ciocore.data.data(). In the Maya and Cinema4d plugins, there's a use_fixtures checkbox to enable this.
To create fixtures, you can either call the endpoints once and paste the JSON, or simply download the ready-made files here.