Open file(s) in a client workspace for addition to the depot.
Assigns a specific file type to a new file, overriding any settings in the typemap table
p4 add -t binary file.pdf
Opens all the files within the user’s current directory for add, and links these files to changelist 13.
p4 add -c 13 *
Opens all *.c files in the user’s ~/src directory for add; also opens the README file in the user’s current working
directory for add. These files are linked to the default changelist.
p4 add README ~/src/*.c
Opens a file named *.c for add.
p4 add -f *.c
Perform administrative operations on the server.
Stop the Perforce server
p4 admin stop
Create or edit a changelist specification.
Create a new changelist.
Edit previously submitted changelist 25. Administrator or superuser access is required.
p4 change -f 25
List submitted and pending changelists.
Open file(s) in a client workspace for deletion from the depot.
Opens the file called README in the depot’s top level directory for deletion. The corresponding file within the client workspace is immediately deleted, but the file is not deleted from the depot until the default changelist is submitted.
p4 delete //depot/README
Opens file in the current client workspace for deletion. The file is immediately removed from the client orkspace, but won’t be deleted from the depot until changelist 40 is sent to the server with p4 submit.
p4 delete -c 40 file
Opens file(s) in a client workspace for edit.
Opens all files ending in .txt within the current directory’s doc subdirectory for edit. These files are linked to the default changelist; these files are stored as type text with keyword expansion.
p4 edit -t text+k doc/*.txt
List files and revisions that have been synced to the client workspace
Display information about the current client and server.
Open files for branching or merging.
Branch or merge all files in //depot/dev/… to the corresponding files in
//depot/rel2/… If there is no corresponding file in //depot/rel2/…, this creates it.
p4 integ //depot/dev/… //depot/rel2/…
Create or edit a defect, enhancement request, or other job specification.
Log in to a Perforce server by obtaining a ticket.
Change a user’s Perforce password on the server.
Resolve conflicts between file revisions.
Discard changes made to open files.
Revert all open files to their pre-opened state.
p4 revert //depot/…
Send changes made to open files to the depot.
Submit the default changelist. The user’s revisions of the files in this changelist are stored in the depot.
Submit changelist 41.
p4 submit -c 41
Copy files from the depot into the workspace.
p4 sync file.c#4
p4 sync //depot/proj1/…@21
Create or edit Perforce user specifications and preferences.
View the user specification of Perforce user joe.
p4 user joe
Edit the user specification for the current Perforce user.
Delete the user specification for the Perforce user sammy.
p4 user -d sammy