Shadow Copying in Perforce?

727 Views Asked by At

I am working with a team and we are trying to restructure our approach to managing our perforce depo. Our current solution is to maintain a separate "work" folder structure. Each person is limited to their own work folder a swell as discipline folder. We have people coming in and out of the project constantly so this way no one in art can mistakenly screw something up in programming. Once assets (this is a game) are done, they should be copied by one of the team leaders into the actual build. This way things can be kept clean and organized outside of the build itself does not get cluttered with peoples temporary files/solutions/code/etc. The issue that I have with this approach is that aspect that... we already have a copy of the file in our work structure. There is no reason to do a deep copy into the game folder. Is there a way to shadow copy the file into the game build from the asset which exists the personal folder of a user/group? We are using the visual (p4v) client.

1

There are 1 best solutions below

2
On

On the depot side Perforce does lazy copying, so you only have one copy internally. That is, Perforce uses metadata and internal logic to fetch the file when users browse and sync. Only when someone changes the file does the depot contain the additional information regarding these changes. What this means is that you can branch very large file trees without requiring massive amount of storage for your depot.

As a side note (and for the sake of completeness), on the client side, when you branch into a new location, Perforce creates a local copy as a convenience to you. The assumption is simply that creating a new branch means you want to work on it right away. If this is not the case, or if you're branching a very large tree that would take up a great deal of storage on your hard drive, you can branch using the -v option (v stands for virtual), as follows:

p4 integ -v //depot/game/... //depot/workspace/...

You can still retrieve the files by syncing to them afterwards.