SuggestBranchName
The script gets the pack name as input and suggests an available branch name, for example: pack name is "MyPack" the branch name will be "MyPack". If a branch with the name "MyPack" exists, the script return "MyPack_1".
python · XSOAR CI/CD
Details
| ID | SuggestBranchName |
|---|---|
| Language | python |
| From Version | 6.0.0 |
| Docker Image | demisto/python3:3.12.13.10116658 |
README
The script gets the pack name as input and suggests an available branch name, for example:
pack name is “MyPack” the branch name will be “MyPack”.
If a branch with the name “MyPack” exists, the script return “MyPack_1”.
Script Data
| Name | Description |
|---|---|
| Script Type | python3 |
| Cortex XSOAR Version | 6.0.0 |
Used In
This script is used in the following playbooks and scripts.
- Pull Request Creation - Github
- Pull Request Creation - Gitlab
- Pull Request Creation - Bitbucket
Inputs
| Argument Name | Description |
|---|---|
| pack | The name of the pack. |
| use_command | Which command to use. Possible commands: gitlab-branch-list GitHub-get-branch * bitbucket-branch-get |
Outputs
| Path | Description | Type |
|---|---|---|
| AvailableBranch | Available branch name based on the pack name. | string |
args: - description: The name of the pack. name: pack required: true - auto: PREDEFINED description: Which command to use. name: use_command predefined: - gitlab-branch-list - GitHub-get-branch - bitbucket-branch-get comment: | The script gets the pack name as input and suggests an available branch name, for example: pack name is "MyPack" the branch name will be "MyPack". If a branch with the name "MyPack" exists, the script return "MyPack_1". commonfields: id: SuggestBranchName version: -1 contentitemexportablefields: contentitemfields: fromServerVersion: '' dockerimage: demisto/python3:3.12.13.10116658 enabled: true name: SuggestBranchName outputs: - contextPath: AvailableBranch description: Available branch name based on the pack name. type: string runas: DBotWeakRole script: '' scripttarget: 0 subtype: python3 tags: [] type: python fromversion: 6.0.0 tests: - No tests (auto formatted)