Example of perforce checkout rules
Hi,
I am using server side checkout that looks like this
Perforce root
//depot/... //team-city-agent/depot/...
In perforce I have
//depot/main
//depot/software
//depot/release/X/main
//depot/release/X/software
My checkout rules for head are:
-:.
+:main=>main
+:software=>software
I want to get only main and software and avoid getting everything else under //depot/...
checkout rules for release are:
-:.
+:release/X/main=>main
+:release/X/software=>software
With this setup I got the entire contents of P4 depot on my TC server. Could you please provide and example for P4?
I am thinking to try this, to follow P4 syntax:
-:.
+://depot/main/..=>main
+://depot/software/..=>software
-:.
+://depot/release/X/main/..=>main
+://depot/release/X/software/..=>software
With the size of my depot and TC server running out of disk space it is kind of hard to learn by trying. Thank you.
Vadim.
Please sign in to leave a comment.
Hello Vadim,
Try using the following Perforce rules:
//depot/main/... //team-city-agent/main/...
//depot/software/... //team-city-agent/software/...
and don't use checkout rules for this case at all.
Hope this helps,
KIR
Hi Kirill,
Thanks for prompt response. This is exactly how I have it setup right now, but now we upgraded to enterprise :-) and I wanted add more build configurations and manage them with templates. I will create template per VCS root for now. Thanks.
Vadim.
P.S.
This is the docs that describe what I was trying to do:
http://confluence.jetbrains.net/display/TCD5/Build+Configuration+Template
Example of Configuration Parameters Usage
The following example shows how the configuration parameters work.
Assume that you have two similar build configurations that differs only in checkout rules. For instance, let's say for the first configuration checkout rules should contain ':release_1_0 => .', and for the second configuration — ':trunk => .'. It would be useful to have one build template to associate with both configurations. In this case you will need means to change checkout rules in each build configuration itself.
To solve the task, you need to perform the following procedure:
The task is solved: we have two build configurations associated with one template and individual checkout rules.
In such manner you can create a configuration parameter and then reference it from any build configuration, which has a text field.