Helix Core is now P4. Product user interfaces will be updated soon. Learn more >>

P4 for Jenkins Documentation | 1.17.3

# Streams workspace

Create a workspace view based on a stream spec template. The workspace name is auto-generated using the format you define. Use this workspace for Matrix builds where multiple workspaces are needed.

1. In Workspace behaviour, ensure that Streams (view generated by Perforce for each node)is selected.
2. Use Character Set to set the character set used by Jenkins when syncing files from the Perforce P4 Server. This should be set to none unless the workspace is connected to a Unicode enabled P4 Server.
3. In Stream Codeline specify the full Perforce depot path for the stream used to create or update the Jenkins build workspace. If you are connected to a P4 Server, streams will be auto suggested as you type.
4. In Stream at change enter a changelist number to reproduce the stream layout from that point in time. This locks the workspace view to the stream spec as it existed at or before the specified changelist. Leave blank to use the latest stream spec.
5. (Optional) Select Pin the workspace to the build host to restrict the workspace to a specific agent. You do not always need to select this option, as including`${NODE_NAME}` in the workspace name already ensures each agent uses a unique workspace.

6. In Workspace name, enter a unique name for the manual workspace. Each Jenkins agent node must use a distinct Perforce workspace. The name is generated using a format string that substitutes predefined variables. You must include at least one variable, but it's recommended to use the following as a minimum:

   jenkins-${NODE_NAME}-${JOB_NAME}-${EXECUTOR_NUMBER}

   For more information about variables, see Variable Expansion

   Pipeline:

   - Use a unique workspace name for the Jenkinsfile that will not get reused by the sync steps in the script. A postfix of -script will help to identify the workspace's use and make it unique from code sync steps.

   - Variables in the script for the workspace name must be surrounded by single quotes as shown:

   name: 'jenkins-${NODE_NAME}-${JOB_NAME}-${EXECUTOR_NUMBER}',

   Using full double quotes " expands the variables early and the script will fail.

Your search for returned results