p4 jobspec
Edit the jobs template to change, add, or remove spec fields for job forms.
Syntax
p4 [g-opts] jobspec
p4 [g-opts] jobspec [-i]
p4 [g-opts] jobspec -o
Description
The p4 jobspec
command presents the
Helix Core Server
administrator with a form in which job fields can be edited, created,
deleted, and refined.
Form Fields
Field Name | Description |
---|---|
|
A list of field definitions for your site’s jobs, one field per line. Each line is of the form code name datatype length fieldtype. Important
When adding a new field in 2019.2 or later, the administrator can enter its code by using the optional placeholder value NNN. If the administrator choses this option, the server will assign an appropriate value. Upon saving the jobspec, the next available code value in the 101-119 range will be automatically generated and saved. The values 101 through 105 are reserved for Helix Core, so the effective range is currently 106-199. If the number of fields exhausts the range, new codes are assigned unique values greater than or equal to 10000. Alternatively, the administrator can specify a numeric value. When the administrator saves the spec, a message might indicate that the specified value is not available.
|
|
Contains a lists of fields and valid values for
Enter one line for each field of datatype
|
|
Contains a list of fields and their default values for each
field that has a fieldtype of Each line must contain the field name and the default value, separated by a space. For example:
Any one-line string can be used, or one of three built-in variables:
See Usage notes for special considerations for field 102. |
|
Textual comments that appear at the top of each See Usage notes for special considerations for these comments if your users need to enter jobs through P4V, the Helix Core Visual Client. |
Options
|
Read the jobspec form from standard input. |
|
Write the jobspec form to standard output. |
|
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 |
admin, or |
-
Do not attempt to change, rename, or redefine fields 101 through 105. These fields are used by Helix Core Server and should not be deleted or changed. Only use
p4 jobspec
to add new fields to your jobs.Field 101 is required by Helix Core Server and cannot be renamed or deleted.
Fields 102 through 105 are reserved for use by Helix Core Server applications. Although it is possible to rename or delete these fields, it is highly undesirable to do so. Helix Core Server applications might continue to set the value of field 102 (the
Status
field) toclosed
(or some other value defined in thePresets:
for field 102) upon changelist submission, even if the administrator has redefined field 102 to for use as a field that does not containclosed
as a permissible value, leading to unpredictable and confusing results. - The information in the
Comments
fields is the only information available to your users to tell them how to fill in the job form, and is also used by P4V, the Helix Core Visual Client, to display ToolTips. -
The
Presets:
entry for the job status field (field 102) has a special syntax for providing a default fix status forp4 fix
,p4 change
-s, andp4 submit
-s.By default, a job’s status is set to closed after you use
p4 fix
,p4 change
, orp4 submit
. To change the default fix status fromclosed
to some otherfixStatus
(assuming that you have defined thefixStatus
as a validselect
setting in theValues
field), use the special syntax of
in thejobStatus
,fix/fixStatus
Presets
field for field 102 (job status). To change the behavior ofp4 fix
,p4 change
, andp4 submit
to leave job status unchanged, use the specialfixStatus
ofsame
. - See the example of a customized jobspec in the "Customizing Perforce: Job Specifications" chapter of the Helix Core Server Administrator Guide.
Related commands
To create, edit, or view a job |
|
To attach a job to a changelist |
|
To list jobs |
|
To list jobs attached to specific changelists or changelists attached to specific jobs |