p4 change
Synopsis
Create or edit a changelist specification.
The command p4 changelist
is an alias for p4
change
.
Syntax
p4 [g-opts
] change [-s] [-f | -u]
[[-O] changelist
]
p4 [g-opts
] change -d [-fsO]
changelist
p4 [g-opts
] change -o [-sf] [[-O]
changelist
]
p4 [g-opts
] change -i [-s] [-f |
-u]
p4 [g-opts
] change -t restricted |
public [-U user
] [-fuOI]
changelist
p4 [g-opts
] change -U
user
[-t restricted | public] [-f]
changelist
p4 [g-opts
] change -d -f
--server=serverid
changelist
Description
When files are opened with p4 add
, p4
delete
, p4 edit
, or p4
integrate
, the files are listed in a changelist. Edits to the
files are kept in the local client workspace until the changelist is
sent to the depot with p4 submit
. By default, files
are opened within the default changelist, but multiple changelists can
be created and edited with the p4 change
command.
p4 change
brings up a form for editing or viewing in the editor
defined by the environment variable P4EDITOR
. When no
arguments are provided, this command creates a new, numbered changelist.
(All files open in the default changelist are moved to the new
changelist.)
The command p4 -Ztag change -o
displays, in addition to other
information, the access time for shelved files. You can use this
information to determine if a shelved file has been abandoned and needs
to be removed.
Changelist numbers are assigned in sequence; Perforce may renumber changelists automatically on submission in order to keep the numeric order of submitted changelists identical to the chronological order.
To edit the description of a pending changelist, or to view the fields
of a submitted changelist, use p4 change changelist
.
If p4 submit
of the default changelist fails, a
numbered changelist is created in its place. The changelist must be
referred to by number from that point forward.
Form Fields
Field Name | Type | Description |
---|---|---|
|
Read-only |
Contains the changelist number if editing an existing changelist, or
|
|
Read-only |
Name of current client workspace. |
|
Read-only |
Date the changelist was last modified. |
|
Read-only |
Name of the change owner. The owner of an empty pending changelist (that is, a pending changelist
without any files in it) can transfer ownership of the changelist to
another existing user either by editing this field, or by using the The specified owner does not have to be a Perforce user. You might want to use an arbitrary name if the user does not yet exist, or if you have deleted the user and need a placeholder until you can assign the spec to a new user. |
|
Read-only |
The status is |
|
Writable, mandatory |
Textual description of changelist. This value must be changed before submission. If you do not have access to a restricted changelist, the description is replaced with a "no permission" message. |
|
List |
A list of jobs that are fixed by this changelist. The list of jobs that appears when the form is first displayed is
controlled by the |
|
Writable, optional |
Type of change: The Public changes are displayed without restrictions. By default, changelists are |
|
List |
The list of files being submitted in this changelist. Files can be deleted from this list, and files that are found in the default changelist can be added. |
|
Read-only |
Displays the name of the user who ran the This field is primarily useful for distributed versioning (DVCS) scenarios, in which changelists are copied from one server to another, and help you correlate the changelist’s basic identity as it is copied. In such configurations, Perforce recommends using the |
|
Writable, mandatory |
Contains a label which uniquely identifies this changelist across all servers where it has been fetched, pushed, or unzipped. This field is primarily useful for distributed versioning (DVCS) scenarios, in which changelists are copied from one server to another, and help you correlate the changelist’s basic identity as it is copied. In such configurations, Perforce recommends using the |
Options
|
Delete the changelist. This is usually allowed only with pending
changelists that contain no files or pending fixes, but the
superuser can delete changelists under other circumstances with the
addition of the If you try to forcibly delete a changelist whose client is bound to
another server, you need to specify the |
|
Force option. Allows the description, modification date, or user of a
submitted changelist to be edited. Editing a submitted changelist
requires The |
|
Forcibly delete a previously submitted changelist. Only a Perforce
administrator or superuser can use this command, and the changelist
must have had all of its files removed from the system with
|
|
Read a changelist description from standard input. Input must be in
the same format used by the |
|
Write a changelist description to standard output. |
|
If a changelist was renumbered on submit, and you know only the
original changelist number, use |
|
Specifies that the changelist number is the Identity field of a changelist. |
|
Allows jobs to be assigned arbitrary status values on submission of
the changelist, rather than the default status of On new changelists, the fix status is displayed as the special status
This option works in conjunction with the |
|
If you try to forcibly delete a changelist whose client is bound to
another server, you need to specify the This variant of the |
|
Change a submitted changelist’s type to either |
|
Update a submitted changelist. Only the The |
|
The |
|
See “Global Options”. |
Usage Notes
Can File Arguments Use Revision Specifier? | Can File Arguments Use Revision Range? | Minimal Access Level Required |
---|---|---|
N/A |
N/A |
|
- You should create multiple changelists when editing files
corresponding to different logical tasks. For example, if edits to
files
file1.c
andfile2.c
fix a particular bug, and edits to fileother.c
add a new feature,file1.c
andfile2.c
should be opened in one changelist, andother.c
should be opened in a different changelist. p4 change
changelist edits the specification of an existing changelist, but does not display the files or jobs that are linked to the changelist. Usep4 opened
-c changelist
to see a list of files linked to a particular changelist andp4 fixes
-c changelist
to see a list of jobs linked to a particular changelist.- To move a file from one changelist to another, use
p4 reopen
, or usep4 revert
to remove a file from all pending changelists.
Examples
|
Create a new changelist. |
|
Edit previously submitted changelist 25. Administrator or superuser access is required. |
|
Delete changelist 29. This succeeds only if changelist 29 is |