The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Access to development-wise smart values in Jira Automation

Jira automation users tend to miss out that smart values - development (i.e., branch, commit, pull request) are only available via the DevOps triggers. I was one of those, to be honest. This article introduces a tip on how to make it accessible via any triggers such as the "Scheduled".

 

(1) Create a trigger

As an example, I'll make the commit URL accessible in a component hooked by any triggers. As mentioned before, those development-wise smart values are only available via the trigger corresponding to the entity which you want to access. That means, in my case, I need to choose the "Commit created".

devops-triggers.png

(2) Set entity property

Then set the value {{commit.url}} as an issue property. You can name the key whatever you want. That is it! As the entity property is accessible via any triggers, now you can retrieve the latest commit URL at any component. For instance, you can refer to the stored value with {{issue.properties.commitUrl}}.

set-issue-entity.png

 

(3) Optional: how to debug the rules

I recommend you to place the "Log action" in case you need to debug the rule.

audit-log.png

 

Feel free to post a comment if you found anything unclear.

2 comments

Comments for this post are closed

Community moderators have prevented the ability to post new comments.

M Amine
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
September 26, 2020

thank you @K. Yamamoto for this great tip. Automation is really helpful.

Like K. Yamamoto likes this
Thomas Godon
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 4, 2021

is there a way to get the branch name where the commit has been made during a commit created trigger?

Like Olga Dayneko likes this
TAGS
AUG Leaders

Atlassian Community Events