How can i do to install JIRA Commit Acceptance Plugin at Jira 6?

How can i do to install JIRA Commit Acceptance Plugin at Jira 6? I m using linux. I downloaded commitacceptance-1.6.0.jar and puted in the /lib directory on linux, but nothing happens. what else should I do?

3 answers

I'm following this documentation, but I'm still having problems. The documentation says nothing about jarfile (commitacceptance-1.6.0.jar). I really need it?

My files are below:

My pre-commit:

#! / Bin / sh

/ Usr/bin/python / data / svn / testejira / hooks / jira-client.py $ 1 $ 2

My jira-client.py:

#! / Usr / bin / python



# JIRA commit acceptance python client for SVN

# Author: istvan.vamosi @ midori.hu

# $ Id: jira-client.py 20980 2009-07-23 06:16:03 Z $ dchui



import os

import sys

import urlparse

import xmlrpclib



# Configure JIRA access

# ("ProjectKey" can contain multiple comma-separated JIRA project keys like "projectKey = 'TST, ARP'."

# If you specify multiple keys, the commit will be accepted if at least one project listed accepts it.

# Or you can specify "projectKey = '*'" using force to commit the global acceptance settings if you do not

# Want to specify any exact project key.)

jiraBaseURL = '10.6.8.38:8080'

jiraLogin = 'admin'

jiraPassword = '123456'

projectKey = '*'



# Configure svnlook path

svnlookPath = '/ usr / bin / svnlook'
# Get committer

try:

f = os.popen (svnlookPath + 'author' + sys.argv [1] + '- transaction' + sys.argv [2])

committer = f.read ()

if f.close ():

raise 1

committer.rstrip committer = ("\ n \ r")

except:

print >> sys.stderr, 'Unable to get committer with svnlook.'

sys.exit (1)



# Get commit message

try:

f = os.popen (svnlookPath + 'log' + sys.argv [1] + '- transaction' + sys.argv [2])

commitMessage = f.read ()

if f.close ():

raise 1

commitMessage commitMessage.rstrip = ('\ n \ r')

except:

print >> sys.stderr, 'Unable to get commit message with svnlook.'

sys.exit (1)



# Print arguments

print >> sys.stderr, 'Committer' + committer

print >> sys.stderr, 'Commit message: "' + commitMessage + '"'



# Invoke JIRA web service

xmlrpcUrl jiraBaseURL + = '/ rpc / xmlrpc'

try:

s = xmlrpclib.ServerProxy (xmlrpcUrl)

acceptance, comment = s.commitacc.acceptCommit (jiraLogin, jiraPassword, committer, projectKey, commitMessage). split ('|');

except:

acceptance, comment = ['false', 'Unable to connect to the JIRA server at "' + jiraBaseURL + '".']



if acceptance == 'true':

print >> sys.stderr, 'Commit accepted.'

sys.exit (0)

else:

print >> sys.stderr, 'Commit rejected:' + comment

sys.exit (1)

Yes, you need commitacceptance-1.6.0.jar. Install it into the atlassian-jira/WEB-INF/lib folder. Verify that it shows up in the left column of your JIRA Administration page. Lastly, make sure the you have "Accept remote API calls" set to "ON" within the General Settings of your Administration page.

Commit Policy Plugin provides the same base functionality and a lot more, and it can be installed with a click via the Administrations -> Add-ons -> Find New Add-ons screen. The installation instructions are explain in this page, in the "Installation tab".

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jun 12, 2018 in Bitbucket

Do you use any Atlassian products for your personal projects?

After spinning my wheels trying to get organized enough to write a book for National Novel Writing Month (NaNoWriMo) I took my affinity for Atlassian products from my work life and decided to tr...

23,028 views 26 12
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you