Skip to content
This repository was archived by the owner on Sep 20, 2024. It is now read-only.

Perforce Integration

Rob Blau edited this page May 27, 2017 · 19 revisions

Introduction

The Shotgun Toolkit Perforce integration streamlines the process of working with Perforce from within the various Toolkit apps and engines.

<iframe src="//www.youtube.com/embed/NFgmyM0Yp_o?rel=0" width="600" height="400" frameborder="0" allowfullscreen class="drop-shadow"></iframe>

Perforce operations are built into the standard Toolkit File Manager, Publish and Loader apps so they just happen as part of the normal workflow. Perforce changes and file revisions are then tracked in Shotgun against the correct assets and tasks. This frees up your artists to concentrate more on creating amazing assets and less on the process of managing those assets within Perforce.

Who is this for?

The initial release of the Perforce integration is targeted at a typical Games workflow where Artists will usually work with the latest version of assets and files.

It doesn't provide a VFX workflow where artists will often need to work with older versions of an asset. However, this is something we would be very interested in discussing with anybody that wants to work with Perforce in this way so please contact support@shotgunsoftware.com if this is something you would be interested in.

Implementation

The integration consists of a number of components. These include a new framework, two new apps and a set of custom hooks that work in conjunction with the other Toolkit apps to make them Perforce aware:

1. Perforce Framework

The Perforce framework contains a set of common functionality that is then used by the other apps and hooks to provide the Perforce integration.

2. Multi Perforce App

This app provides common Perforce related commands across the different engines & dcc packages (e.g. Maya & Photoshop).

LINKBOX_APP:shotgunsoftware/tk-multi-perforce:Take a look at the functionality the Perforce app provides.

3. Custom hooks

The custom hooks provided as part of the framework are where the integration actually happens. Custom hooks for the File Manager allow it to sync latest versions and check files out whilst the hooks for the Publish app allow it to check files back in as part of the publish process.

4. Perforce Sync Daemon

Finally, the Perforce sync daemon creates entities in Shotgun for any newly submitted Perforce file revisions and changes. These are created with links to the correct entities (e.g. Assets) and tasks as required.

LINKBOX_APP:shotgunsoftware/tk-shell-perforcesync:Take a look at how the Perforce Sync app works.

Note: it's important that this daemon is running to ensure that all changes are synced in a timely fashion between Perforce and Shotgun. Please read the app documentation for further details.

Restrictions

There are currently some restrictions when using Toolkit with Perforce - these are actively being addressed and will be removed in a future release.

  1. Perforce Workspace Mapping - currently, all users must have their workspace mapped to the same absolute local path. This must be the same as the Toolkit Primary file storage as configured when the project is setup with Toolkit.
  2. Configuration location - this must currently live on a shared network drive accessible to all users.
  3. Multiple storage roots are not currently supported.

Configuration

We provide a step by step guide on how to take a configuration and update it for Perforce compatibility. This involves updating some settings on your Shotgun site, adding your Perforce server information to your configuration, setting up your workspace, updating your directory structure and file naming conventions, and updating your apps and hooks for Perforce.

LINKBOX_DOC:61:Adding Perforce support to a configuration.

Feedback

As with everything to do with Toolkit, we are always very interested in discussion and any feedback that you may have. Please post on our forums or contact support@shotgunsoftware.com if you have any comments.

Clone this wiki locally