Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Image Removed
Image Added

About

Excerpt

Script Templates are an easy way to add automated actions instantly and without any coding. We have taken some of the most common types of scripts and converted them into an easy to use interface.

Contents

Table of ContentsminLevel1maxLevel2

However, this does not mean scripting is not used. When creating the action using a template the script gets generated for you. We do this because we firmly believe that script is the most flexible, most powerful way to incorporate automation into your Jira system. We release that not everyone is comfortable scripting so we created the templates to guide users through the process.

Image Removed
Image Added

In the image above, you can see the script getting written in the SIL code preview panel as the user enters information into the input fields. We do this with the hope that after seeing real word applications of the scripts you will become more familiar with the way they are written and gain confidence in modifying and writing the scripts in the future.

The scripts, after being generated, are also automatically applied so that little to no experience to the administration of Jira is required. However, these templates are designed to be simple guides and continued reliance on them for Jira configuration could result in a less than optimal configuration. It is still advised that someone with more experience reviews the configuration changes after they are applied.

Who are the templates for?

The Script Templates are for Jira administrators wishing to gain the ultimate power of script based automation but are confused or intimidated by the process. They are for admins or Product Owners who wish to gain the benefits of automation immediately without prior scripting knowledge or experience. They are for users who want to learn by doing instead of reading or watching videos.

Script templates are not for the thousands of existing SIL scripting ninjas already using Power Scripts or related apps. We have built some exiting new tools for them so they will be fine.

Where can they be found?

The Script Templates can be found in multiple places.

Jira Administration

Primarily they can be found on the “Find New Apps” or “Manage Apps” administrative pages in Jira.

Image Added

When using script templates from the Jira admin pages, all script types will be available for use

Image Added

Workflows

Additionally, script templates can also be found in other areas like while editing the workflows. You must first add a SIL Condition, SIL Validator, or SIL Post Function to the workflow as seen below.

Image Added

As seen below, when configuring the SIL Post Function the user can choose between adding a new template, writing a new script, or reusing an existing script.

Image Added

However, it is important to note that the templates will be filtered based on the type of workflow action being configured. So, for example, when setting up a SIL Post Function, only post function script templates will be available for use.

Image Added

What happens when the template is applied?

When a template gets applied, the script that was seen in the preview window actually gets created in the system. The SIL Manager is the code editor for SIL scripts and holds the repository for all the scripts used by Power Scripts. Inside this repository you will find a folder called generated_templates. Inside this folder will be subfolders that correspond to different script types and under those you will find that actual script that was generated.

Image Modified

Next, a configuration must be added so that Jira knows which script corresponds to specific events or actions. For example, for a listener script to run it must be associated with an internal event within Jira. In the example below we can see which scripts correspond to events like “Issue Closed” and “User Created”.

Image Removed
Image Added

Many configurations are found within the Power Scripts administration section of the Jira admin. However, this is not true for all of them. Some configurations, like post-functions, are added to the issues workflow. If not familiar with editing workflows this may not seem very straight forward so the configurations will get added to those workflows automatically.

Our hope is for you to then investigate the script and the configuration so you can see how these two things relate to each other and how they get configured. Our main goal is to guide you through setting up these configurations so that you can set them up without the assistance of the templates in the future.

How to make changes existing template scripts?

As mentioned above, there are script files that get created when a template is applied. This means that changes to the applied template can be made directly in those scripts so that it can be customized to your specific needs. Changing the code within a script file does not affect the configuration. This changes can be made independently without updating the workflow or any other type of configuration.

Note

WARNING: Changing the name of a script or moving its location to a different folder will impact existing configurations since the configuration will no longer be able to locate that file. If you wish to change the name or move the file location the configuration needs to updated.

What type of templates are available?

Validator Templates

Insert excerpt
Validator Templates
Validator Templates
nopaneltrue

See more…

Condition Templates

Insert excerpt
Conditions Templates
Conditions Templates
nopaneltrue

See more…

Post-Function Templates

Insert excerpt
Post-Function Templates
Post-Function Templates
nopaneltrue

See more…

Listener Templates

Insert excerpt
Listener Templates
Listener Templates
nopaneltrue

See more…

Recurrent (Scheduled) Job Templates

Insert excerpt
Recurrent (Scheduled) Job Templates
Recurrent (Scheduled) Job Templates
nopaneltrue

See more…

Live Fields Templates

Insert excerpt
Live Field Templates
Live Field Templates
nopaneltrue

See more…

Custom Field Templates

Insert excerpt

Conditions

Custom Field Templates

Conditions

Custom Field Templates
nopaneltrue

See more…

Notification Templates

Insert excerpt

Conditions

Notification Templates

Conditions

Notification Templates
nopaneltrue

See more…

User Templates

Insert excerpt

Conditions

User Templates

Conditions

User Templates
nopaneltrue

See more…

Will new templates be added?

Yes, from time to time new templates will be created and added to the list. The templates chosen for created will be determined by demand and specific templates can be requested for consideration through our support portal.

However, the goal of these templates is to provide you with an example of how to create a similar solution, not to necessarily take all of the work out of creating a new script and solve everyone's problems. Again, we firmly believe that scripting makes the most flexible and powerful solutions and which to guide you into becoming a SIL scripting ninja!

Contents

Table of Contents
minLevel1
maxLevel2