Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How to start (script runner ) custom groovy script post function?

B September 29, 2015

Hi all,

   I want start script runner - custom groovy script post functions, any one refer few links,

thanks.

 

7 answers

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

4 votes
Jens Kisters __SeibertSolutions
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 Leaders.
June 12, 2016

I didn't find the adapavist docs very helpful.

This guide did the trick for me:

http://igorpopov.io/2014/11/24/rocking-with-jira-script-runner/

Judah September 27, 2018

Agreed. The Adaptavist docs need some T.L.C. 

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 27, 2018

I keep asking them for a new version.  There's an overhaul of the UI for SR coming and hopefully we'll be getting better docs with it.

My instinct is the docs are accurate, but written by developers for developers.  Not for beginners or even intermediate level users.  The example the team can't argue is below:

I go to look for stuff on writing a scripted conditions and it starts with 'what a condition is'.  That's fine.  There's then a massive chunk of text all about caching and the internals of Jira.  That's dreadful, because 99.99% of the people landing on this page need "here's a simple condition" next, not an essay that's utterly irrelevant to what they're trying to do!

Greg Elofson October 18, 2018

I think the utter disregard for useful documentation is what drives users to Power Scripts...it's that bad

1 vote
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 30, 2015

I'm not sure what you mean by "start" in that question.

If you mean "start running a post function script", then you don't really.  You transition issues through the workflow so that the post functions are run by the system.  OR you can use the script console to run test scripts.

If you mean "get started with writing scripts for post functions", start at https://scriptrunner.adaptavist.com/latest/jira/quickstart.html - loads of background, recipes and example code there!

0 votes
prudhvi godithi November 28, 2018

Hey is there a sample script in built in for confluence script runner plugin so that I can start modifying it, for attachment scan while uploading and stop them from uploading with a message if it has sensitive data ?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 28, 2018

No, because that would be out of context and not make that much sense.

The way to detect this won't work for you either - you can detect "attachment added" but it's too late by then - the attachment will have been uploaded.  You could scan and delete it, but that will mess your users around.

prudhvi godithi November 28, 2018

Thank you soo much, is it possible, once the attachment is uploaded to scan and then drop a comment on that space saying it has sensitive data, i have a script that scans the attachments, looking for a way to run it in groovy and call that shell script once the attachment is uploaded then scan it, if it has sensitive data then comment on the space with a random message. Is there a groovy way or some other way to start with this? To scan the attachment once uploaded and then comment with message in regards to remove that attachment.? 

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
October 1, 2015

That link goes to documentation on scripted post functions for me. What are you seeing?

0 votes
B September 30, 2015

Hi Andrew Boutin,

Thanks for reply, As you maintained link(https://scriptrunner.adaptavist.com/latest/jira/custom-workflow-functions.html#_post_functions) is does't have any post functions, I have checked there.

Thanks.

 

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

TAGS
AUG Leaders

Atlassian Community Events