¿How to store and access configuration data in Jira for Groovy Scripts?

1. Place a file with name credentials.properties Under <script_root> : app.url=http://example.com app.user=myuser app.password=secret 2. Create an Accessor class in <script_root>/mycompany/MyCompanyProperties.groovy: package mycompany import com.onresolve.scriptrunner.runner.ScriptRunner import com.onresolve.scriptrunner.runner.ScriptRunnerImpl import java.nio.file.Files import java.io.File import groovy.util.logging.Log4j @Singleton @Log4j public class MyCompanyProperties {     final String configFileName = ‘credentials.properties’     public Properties getProperties() {         def scriptRoots = ScriptRunnerImpl.getPluginComponent(ScriptRunner).getRootsForDisplay()?.split(“, “)?.toList()…

Read More

Flags Messages in Jira

Sometimes is difficult to extract this info, here the documentation and examples: Link to the documentation Name Type Default Description title String The title text of the flag. body String The body text of the flag. type String info Sets the type of the message. Valid options are “info“, “success“, “warning” and “error“. close String…

Read More

Curso de desarrollo Groovy para Jira Server

Objetivos En el curso instalaremos Jira Server y Adaptavist Scriptrunner (antiguamente conocido como Groovy Scriptrunner). Explicaremos: Script fields, Script Postfunctions, Script Conditions, Script listeners, Script services, Escalation services, jql custom functions, Behaviours, built-in scripts y web fragments & custom REST endpoints. Daremos ejemplos y casos de uso, haremos ejercicios prácticos y explicaremos alternativas a Scriptrunner…

Read More

How to install a PHP JIRA REST API Client

In this example, we will try to install in 5 minutes a PHP Jira Client script in a MacOS system. The prerequisites are: (Homebrew) brew for MacOS CURL for MacOS PHP 7 for MacOS Composer for MacOS php-jira-rest-client library Install instructions with example: Download and Install PHP Composer. curl -sS https://getcomposer.org/installer | php Next, run…

Read More