Download

How do I make Perforce stop tracking certain files?

So using Perforce is quite a learning curve when coupled with dealing with the main task of game development. I am doing my best to sort out the issues as they pop up.

Right now I need to deal with the fact that perforce is tracking some folders that shouldn’t be tracked. Like the “Plugins” folder and the “Build” folder. Not sure why these where added since I have them marked for ignore in out ignore-file. My guess is that not everyone has initialized that file on their computers at some point and it has slipped past(probably long ago).

I can’t find a way to remove the folders without them getting removed on my workspace. Is there a way to make P4 “UNTRACK” them?

P4IGNORE!
you actually already have that file, just need to add the unwanted folders there :slight_smile:
tracking Build and Plugins folder is perfectly fine btw, why do want to not track them?

You need a p4ignore file set up. This would be a good start that I use for most projects:



# Ignore project files
/Project.sln
/.idea/
/.vs/

# Ignore generated folders
/Binaries/*
/Build/*
/Intermediate/*
/DerivedDataCache/*
/Saved/*
/enc_temp_folder/*

# Ignore the same things for plugins
/Plugins/**/Binaries/*
/Plugins/**/Build/*
/Plugins/**/Intermediate/*
/Plugins/**/DerivedDataCache/*
/Plugins/**/Saved/*

# Don't ignore icon files in Build
!/Build/Linux
!/Build/Windows


After that, you’ll find the extremely annoying issue that P4 does not actually use this file by default!
Everyone who makes a workspace, has to run this command before doing anything:



p4 set P4IGNORE=.p4ignore


Thanks alot for the list!

We have had a file like this in the repo(not completely the same lines though). And like I said I was the only one on our team to use the terminal command.

I have two questions:

  1. The paths you write in your document, are they relative or absolute? I was under the impression that P4 checked each subfolder bellow the one the file resides in. Is this correct or do I need to the path in order to make it work. I would like to add some of the FMOD-files that I have higher in the hierarchy than the Unreal Project root so I have now placed the ignore file in the top most folder.
  2. That command, is that to be run in the CMD or in P4v? I have run it on my machine and on the other team members computer but the folders are still tracked…
Thanks alot for the help so far!:)

May want to consider only exclude anything that isn’t require by artists from the depot entirely.
Another option is one based on permissions, where you can select only those directories that should be accessible by different user levels.

Be sure to setup your typemap as well.
That way you limit the how many versions of certain files or directories that you keep around.