Hi, Just FYI, if you want to generate links for commits and paste them in Jira there's now a simple way to do it via the jira_link_for_commit.sh script.
I symlink it to $HOME/bin and invoke it via jira_link_for_commit.sh | xclip (I think for Mac you need to replace xclip with something else) which places the link in the clipboard and makes it quite easy to add this information to Jira. Thanks, Robert
--- Begin Message ---This is an automated email from the ASF dual-hosted git repository. rombert pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/sling-tooling-scm.git The following commit(s) were added to refs/heads/master by this push: new 9d97aba Add utility script for generating jira links to commits 9d97aba is described below commit 9d97ababc34f330f885f2548741544c9b16e724b Author: Robert Munteanu <[email protected]> AuthorDate: Mon Dec 18 23:20:12 2017 +0200 Add utility script for generating jira links to commits --- scripts/jira_link_for_commit.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/scripts/jira_link_for_commit.sh b/scripts/jira_link_for_commit.sh new file mode 100755 index 0000000..f524463 --- /dev/null +++ b/scripts/jira_link_for_commit.sh @@ -0,0 +1,12 @@ +#!/bin/sh -e + +if [ $# -eq 0 ]; then + commit=HEAD +else + commit=$1 +fi +hash=$(git rev-parse --short ${commit}) +base=$(git remote get-url origin) +url=${base%.git}/commit/${hash} + +echo "[commit ${hash}|${url}]" -- To stop receiving notification emails like this one, please contact ['"[email protected]" <[email protected]>'].
--- End Message ---
