How to get all SVN commits that don't include Jira error code?

I have a Jira and Fisheye setting, so I can include the Jira key in the commit comment ( Smart Commits ). Fisheye will link the source code and the Jira issue mentioned in the commit.

I would not want to use something like the JIRA Commit Acceptance Plugin to reject transactions without Jira keys. Because it is too restrictive. But still, I would like to track Jira keyless commits.

How to get a report on all SVN compilers that do not include a Jira error in a comment?

+4
source share
1 answer

You can run the following command on UNIX in a directory with your working copy:

svn log | grep -v '\--' | awk 'ORS=(NR%3)?" ":"\n"' | grep -v "[ISSUE_PREFIX]" 

where [ISSUE_PREFIX] is your prefix for JIRA. For example, JPA for issues such as JPA-123.

It will have the following result:

 r33 | user3 | 2011-12-21 16:29:29 +0200 (Wed, 21 Dec 2011) | 1 line Third commit log without JIRA key r22 | user2 | 2011-12-21 16:28:19 +0200 (Wed, 21 Dec 2011) | 1 line Second commit log without JIRA key r11 | user1 | 2011-12-21 16:27:18 +0200 (Wed, 21 Dec 2011) | 1 line First commit log without JIRA key 
+1
source

Source: https://habr.com/ru/post/1395146/


All Articles