perforce

What to enter into “Client” field in the Perforce setup dialog in IntelliJ IDEA 10.5?

落爺英雄遲暮 提交于 2019-12-05 15:37:47
问题 I'm trying to set up Perforce integration in IntelliJ IDEA 10.5.2. There is a field named "Client" that doesn't make sense to me. I get the message "Connection problems: Client Unknown" whatever I type into the field. What should I enter into that field? 回答1: You need to enter the name of your Perforce workspace. If you have set up the command line tool correctly you may run p4 set P4CLIENT on the command-line. If you use the P4V GUI tool, the workspace name is easily found. 回答2: Open P4V and

p4v does not show the complete list of checked out files

邮差的信 提交于 2019-12-05 13:01:41
问题 If I checkout 4000 files in p4v it does not show me the complete list of files in the default changelist. It just says 4000 files checked out. Is there any way that I can view the complete list of 4000 files? 回答1: Open the preferences dialog via the Edit->Preferences menu. Click on "Server Data" and you'll see a setting labeled "Maximum number of files displayed per changelist*:" Raise that to 4000+ and you should see all those files. 回答2: I don't know if it is possible in p4v. In a command

Perforce: Keeping Perforce from altering text-file format

最后都变了- 提交于 2019-12-05 12:51:06
问题 Is there a way to tell Perforce to leave text files alone without setting the file-type as binary? Or barring that, is there a way to tell the Perforce client to diff binaries? Binary usually isn't desirable, because I lose the ability to diff. To clarify: If I edit and make changes to a *.txt file on my window client, newlines will have CR+LF as per the DOS format. But if I P4 sync on a Unix client, it will have LF only. I need Perforce to keep the format as-is, regardless of where the

Can I safely edit a renamed file in perforce

℡╲_俬逩灬. 提交于 2019-12-05 07:35:19
I have a file I need to move that's already under perforce. Once moved it needs some editing - update the package, etc - appropriate to its new location. Should I submit the move changespec and then reopen it for edit, or can I do this in one go? If so, what is the appropriate sequence of events? I have done this before in one go, but depending on your build process, I recommend against it. What I generally do is this: Move the file. If the move needs a change in order to compile, open it for edit and make those changes. Submit the changes, telling perforce to reopen the files for editing.

Perforce client side pre-commit hook

て烟熏妆下的殇ゞ 提交于 2019-12-05 07:06:31
We are using perforce as a source control for Visual studio solution. Working with P4 and P4V. Is it possible to add client side pre-commit hook? for instance to ensure the word "debugger;" is not exist in *.js files. Could find something in Google. Thanks. Perforce triggers can be used to enforce such a policy, but they run in the server, not client-side. So most sites that I'm aware of would enforce a rule such as the one you describe using a change-content trigger in the server. http://www.perforce.com/perforce/doc.current/manuals/cmdref/triggers.html It's not obvious from your question why

xcode4 doesn't support Perforce?

≯℡__Kan透↙ 提交于 2019-12-05 06:40:49
xcode4 doesn't support Perforce? I add a repository in xcode4. Only subversion and Git to choose. how to add a perforce repository? thank you. I threw together a couple of Automator services that let you bind hotkeys for p4 edit/p4 add on the currently open file in Xcode 4. It's not ideal, but it beats switching to terminal or p4v. https://github.com/jcohen/xcode4-perforce-services It's also useful to note that there is a setting in Preferences/Behaviors to add behaviors to particular actions. One of those is Unlock File, which can be bound to a shell script, like the one here: #!/bin/sh

How do I move folders between Perforce “depots”

[亡魂溺海] 提交于 2019-12-05 06:33:54
After deleting my Svn repo by accident the other day I wanted to try something else and I have chosen Perforce as my current versioning tool testing ground. It is going great and I am liking what am seeing in Perforce. Here is my problem. I have submitted my files to my Perforce server and then used my client pcs to grab those projects from the master Perforce server. Now all works great except that I realized that it is possible to use more than a single "depot" in Perforce, and it makes sense to me that I should just move some of those projects to another depot fpr the sake of organization

Vim auto commands: writing a read-only file?

元气小坏坏 提交于 2019-12-05 04:09:52
I'm using Perforce with Vim on Windows. I currently have an auto command set up to open a read-only file for edit when changing it: au FileChangedRO * !p4 edit <afile> Is there any way to set up a similar auto command to execute p4 edit when attempting to write a read-only file rather than edit it? You can use an auto command attached to the BufWritePre event, that checks whether the file is read only or not and executes p4 edit on demand. Something like: autocmd BufWritePre * :if &readonly | !p4 edit % You can give the perforce plugin a shot. I find it very useful. 来源: https://stackoverflow

Perforce fast sync a directory to a clean state

◇◆丶佛笑我妖孽 提交于 2019-12-05 03:44:09
I want a fast solution that does not require force sync that will put a specified directory to its original repository state. same files may be removed from disk same files may be added from disk some files may be modified on disk some files may be marked for removal, addition or modification in perforce All I want is to be sure that after if run the command I will have none of these. p4 -f sync is not an option, I need a faster solution that does minimize networks usage. Just in case someone asks, perforce proxy is out of discussion. I do know that a partial solution is: p4 diff -sd -se /

How to convert Perforce depot locations to client view locations

主宰稳场 提交于 2019-12-05 02:43:15
I'd like to know how to convert Perforce depot locations to client view locations for the purpose of script writing. I have a script that first checks out a file for edit in perforce and then interacts with the file. I need to have the depot location (i.e. \Projects\Project6) converted to the client view location. (i.e. d:\Projects\Project6). Is this possible? I have always used the p4 where command for this. Here is its description from the built-in help: where -- Show how file names map through the client view p4 where [ file ... ] Where shows how the named files map through the client view.