How to upload files from perforce to a place other than the workspace?

I want to get files from Perforce without putting them in the workspace.

eg. I made changes to 2 files.

file1.cs 
file2.cs

Now I want to build a project using the updated file1.cs file, so I want to get the latest files except file1.cs.

I thought I would get another local copy of the project and build it.

+3
source share
7 answers

, Perforce , , , ( ). , , file1.cs, , , , . , , . , , : http://www.perforce.com/perforce/doc.062/manuals/boilerplates/quickstart.html , "Root" , , , P4V . , , .

+1

, , , , p4 print ". :

>p4 print -o fileName.cs //depot/path/to/fileName.cs
+9

, , file1.cs

; file1.cs

, - 56.cs, , 1.cs. , ( ) file1.cs, .

0

Shelve file1.cs, :

p4 shelve file1.cs
p4 revert file1.cs

file1.cs, ( ).

:

p4 unshelve -s CHANGE
0

If you are in the user interface, you can use File-> Export To ... to copy the selected file to any desired folder.

enter image description here

0
source

I found a workaround, but not a solution.
I get another local copy of the project, then create the project and submit the change.

-1
source

I found a simple way to do this with git:

 $ git p4 clone //depot/your/folder
-1
source

Source: https://habr.com/ru/post/1778059/


All Articles