How to semi-automate repetitive tasks
1 Description|2 Confluence example|2.1 Wiki markup|2.2 Result|3 Jira example|3.1 Wiki markup|3.2 Result
Description
Often you need to create a standard set of Confluence pages or Jira issues or similar. The Run CLI Actions in Confluence allows you to semi-automate this process using the power of Appfire Command Line Interface (CLI). The process or activity is easily documented and readily changeable. Confluence page history provides tracking. The Run Self-Service Reports for Confluence should be used to provide a run button and to parameterize some of the data - the technique is demonstrated in Repetitive task using the RUN macro. An alternative is to use the --simulate parameter on the run action and manually remove it when ready to run the actions using preview mode.
Confluence example
Wiki markup
{cli:profile=confluence}
--action run --common "--space zcli"
@DATA:
--action storePage --title "Designs"
--action storePage --title "Design 1" --parent "Designs"
--action storePage --title "Design 2" --parent "Designs"
# Remove comment for this only for UI projects!!!
# --action storePage --title "UI Design 1" --parent "Designs"
{cli}
Result
Run: --space zcli --action storePage --title "Designs"
Page updated: 'Designs'. Page has id: 86245981
Run: --space zcli --action storePage --title "Design 1" --parent "Designs"
Page updated: 'Design 1' as child of 'Designs'. Page has id: 86245982
Run: --space zcli --action storePage --title "Design 2" --parent "Designs"
Page updated: 'Design 2' as child of 'Designs'. Page has id: 86245983
# Only do this page for UI projects
# --action storePage --title "UI Design 1" --parent "Designs"
Run completed successfully. 3 actions were successful
Jira example
Wiki markup
{cli:profile=jira}
h3. JIRA example
{cli:profile=jira}
--action run --common "--project zcli"
@DATA:
--action createIssue --type task --summary "Task 1"
--action createIssue --type task --summary "Task 2"
{cli}
Result
Run: --project zcli --action createIssue --type task --summary "Task 1"
Issue ZCLI-22 created with id 78404. URL: http://localhost:8215/browse/ZCLI-22
Run: --project zcli --action createIssue --type task --summary "Task 2"
Issue ZCLI-23 created with id 78405. URL: http://localhost:8215/browse/ZCLI-23
Run completed successfully. 2 actions were successful
, multiple selections available, Use left or right arrow keys to navigate selected items