Language task: Transfer.yaml
Description
This sample provides the language task configuration to transfer files to members without building. The transferred files are listed as build outputs in the build report. This sample is imported via Languages.yaml.
Version Requirements
This sample contains elements that require build configuration schema version 1.0.1 introduced in DBB 3.0.1.
Actions
- Define sources.
- Define variables.
- Create datasets.
- Loop through steps for each build file.
- Copy each file to respective dataset.
Define sources
Define sources
as a list of file patterns to locate transferable files within the build list.
sources:
- "**.jcl"
- "**.proc"
- "**.cntl"
- "**.rexx"
Create datasets
Create datasets that must exist and be validated before compiling.
datasets:
- name: ${HLQ}.JCL
options: cyl space(1,1) lrecl(80) dsorg(PO) recfm(F,B) dsntype(library)
- name: ${HLQ}.PROC
options: cyl space(1,1) lrecl(80) dsorg(PO) recfm(F,B) dsntype(library)
- name: ${HLQ}.CNTL
options: cyl space(1,1) lrecl(80) dsorg(PO) recfm(F,B) dsntype(library)
- name: ${HLQ}.REXX
options: cyl space(1,1) lrecl(80) dsorg(PO) recfm(F,B) dsntype(library)
Task steps
For each build file, the copy
step will be executed.
Copy step
A conditional copy
step for each file type allows files to be transferred to their repsective dataset. This allows files of different extensions to be copied to different datasets.
For example, the copyJCL
copy
step for JCL files copies the current build file from its HFS source to the //'${HLQ}.JCL(${MEMBER})'
dataset. Notice the ${FILE_EXT} == "jcl"
condition
is defined such that the step will run only for the files with the jcl
file extension.
- step: copyJCL
type: copy
condition: ${FILE_EXT} == "jcl"
source: ${FILE_PATH}
target: //'${HLQ}.JCL(${MEMBER})'
copyMode: TEXT
deployType: JCL