Switches
- Julie Wetherill
- Paul Aloisio
- Emily Kelly
- Former user (Deleted)
Â
Switches
-a [action]
–required – accepts three actions: templatedirs, buildtemplate, and build.
templatedirs
: rebuild the directories in the object template from the information in the project configuration file .buildtemplate
: Create a new batch with objects from template in the specified project.build
: build the descriptors and batch.xml for a specified batch within a specified project using batch, object and directory level property values supplied on command line or/and in the Graphical User Interface (GUI).
-p [project directory path]Â
  – required – indicates the path to the project directory on disk. This path must be created in Batch Builder GUI before using the command line option. The project path cannot be created while executing this command. If path does not already exist the action will fail.-b [batch_name]
   – required for actions buildtemplate and build – name of batch directory. When using buildtemplate action BB2 will create a new batch directory with the name specified by the –b switch, e.g.: batchbuildecli –a buildtemplate –p c:\myproject\ -b new_batch_directory_name. When using the build action, BB2 will process the existing batch directory specified by the –b switch, e.g.: batchbuildecli –a build –p c:\myproject\ -b existing_batch_directory_name.-aleph [object_name1]=[Aleph or Alma ID];[
object_name2]=[
etc.   – optional – system number of corresponding record in HOLLIS. Batch Builder uses this number to pull metadata from the corresponding HOLLIS record into the MODS section of the object descriptor. This switch can be used with action build. [Even thought the name of the switch is 'aleph' the value can be an Aleph or an Alma ID.]Aleph or Alma ID
]
Examples: -aleph obj1=12345;obj2=67890
Note that no other methods of entering aleph id or MODS should be used for the batch if this switch is invoked – such as mapping files with ALEPH IDs, user supplied MODS files, descriptive metadata entered in the GUI or ALEPH IDs supplied in the GUI – otherwise BB will throw an error or silently fail to write the new ALEPH ID into the descriptor.-batchprop [property=value,property=value,property=value...]
– optional – overrides specified project deposit settings for a given batch. The -batchprop argument must be wrapped in quotes to ensure that the entire string is passed correctly to Batch Builder. Each property=value pair should be separated by a comma ','. Repeatable batch property values should be as property=value pairs separated by a comma – e.g.:-batchprop
"successEmail=success1@example.com,successEmail=success2@example.com"
-objectprop [object_name::property=value,property=value;...]
– optional – overrides specified object metadata properties for given objects. The -objectprop argument must be wrapped in quotes to ensure that the entire string is passed correctly to Batch Builder. Each property=value pair should be separated by a comma ','. As properties for multiple objects may be passed, each object property=value block should be separated by a semicolon ";", e.g.-objectprop
object_name1::property=value, property=value;object_name2::property=value,property=value;etc.
-dirprop [object_name::directory_path::property=value,property=value;...]
– optional – overrides specified file metadata property values for given files. The -dirprop argument must be wrapped in quotes to ensure that the entire string is passed correctly to Batch Builder. Each property=value pair should be separated by a comma ','.
Example (using all switches listed above)
C:\BatchBuilder-2.0.50> batchbuildercli -a build -p "C:\my_project\"Â -b batch1Â
–aleph objectname1=12345;objectname2=67890; –batchprop batchName=mybatch{depositAgent}{batchDir}{ss},successEmail=success@me.me,failureEmail=failure@me.me,successMethod=email,depositAgent=12345678"Â
–objectprop objectname1::"metsLabel=some citation information";objectname2::"metsLabel=some citation information2" –dirprop objectname1::image_archmaster::accessFlag=N,isFirstGenerationInDrs=yes,quality=10;objectname1::image_archmaster\image-deliverable::accessFlag=P,isFirstGenerationInDrs=no,quality=5;objectname2::image_archmaster::accessFlag=N,isFirstGenerationInDrs=yes,quality=10;objectname2::image_archmaster\image-deliverable::accessFlag=P,isFirstGenerationInDrs=no,quality=5
On this page: