Information

This site will undergo maintenance on Friday, 26 September at 2:00 AM CDT / 12:30 PM IST and may experience a short period of instability during that time.

TemplatePart - addExcludeByName


TemplatePart - addExcludeByName

Description :

This command adds an exclude to a template part. You must provide the name of a template, the template group, the name and type of the template part, and the path to the server objects you want to exclude.

The model types you can exclude are:

  • DIRECTORY: Directory
  • REGISTRY_KEY: Windows registry key
  • COMPLUS_SUBCAT: Windows COM+ collection
  • COMPLUS_OBJECT: Windows COM+ object
  • METABASE_KEY: Windows metabase key
  • CUSTOM_OBJECT: Custom object
     The software collections you can exclude are:

AIX:

  • AIX_PACKAGE_LIST: AIX packages
  • AIX_PATCH_LIST: AIX patches

HP-UX

  • HP_BUNDLE_LIST: HP-UX bundles
  • HP_PRODUCT_LIST: HP-UX products
  • HP_PATCH_LIST: HP-UX patches

Linux:

  • RPM_LIST: Linux RPMs

Solaris

  • SOLARIS_PACKAGE_LIST: Solaris packages
  • SOLARIS_PATCH_LIST: Solaris patches

Windows

  • WINDOWS_APPLICATION_LIST: Windows applications
  • HOTFIX_LIST: Windows hotfixes

Return type : DBKey

Command Input :

Variable Name

Variable Type

Description

templateGroup

String

Fully qualified name of a template group.

templateName

String

Name of the template containing the part to be modified.

templatePartName

String

Path to the template part to be modified. Note that if you set templatePartType to CUSTOM_OBJECT, then you must set templatePartName to the class name of the custom object as specified in model.xml.

templatePartType

String

Type of template part to be excluded (see description above).

excludePath

String

Path to be excluded.

Example

The following example shows how to exclude all .txt files from a directory in a template:

Script


TEMPLATE_NAME="template1"

TEMPLATE_GROUP="/parent/group1"

ASSET_TYPE="DIRECTORY"

ASSET_PATH="/C"

EXCLUDE_FILES="*.txt"

RESULT=`blcli TemplatePart addExcludeByName $TEMPLATE_GROUP $TEMPLATE_NAME '$ASSET_PATH' $ASSET_TYPE '$EXCLUDE_FILES' `



 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

TrueSight Server Automation Command Line Interface 20.02