Mystery solved. I was adding files with the pattern a\b\c\test\d\e\Fgh.java
.
There was no directive to ignore *.java
. but there was an instruction to ignore test\*
. There were no additional p4Ignore files up and down the tree, though it's a good suggestion to check for such things.
Works as designed. No issue to report.
IntelliJ + Perforce Automatically Ignores New Files
-
01-07-2023 - |
Pregunta
When I add a new (.java
) file to my project in IntelliJ, it does not get automatically added to p4, even though it was configured to do it.
When I try to add it manually to p4 (using p4v -> rclick -> add) it says "ignored file can't be added". I have not done anything to mark this file as "ignored". I have also checked the .p4ignore
file in my p4 client root dir. It does not have any rules targeting that directory or *.java
.
I can go to command line and do p4 reconcile -I
, which has the effect of adding the file to p4. But why do I need to do this? Why don't new files get added to p4 automatically, and why does p4 see them as "ignored"?
I am using IntelliJ 13.1.1 Ultimate on Win7 64-bit with the P4 plugin. Using p4v version "2013-09-24". IntelliJ is configured to silently add new files to p4 (File -> Settings -> Version Control -> Confirmation). The IntelliJ-specific list of ignored files contains only IntelliJ-specific files (*.iws
, .idea/
, etc.).
Solución 2
Otros consejos
There can be multiple P4IGNORE files in your client workspace, not just the one in the client's root directory. The Perforce client-side software will search the directory containing the file to be added, its parent directory, and so forth, looking for P4IGNORE files which control the file ignoring behaviors.