Answer the question
In order to leave comments, you need to log in
How to display the difference between two commits with a link to the post-land commit?
I would like to see what differences the new commit brings.
There is an example design:
git rev-list --ancestry-path $old_hash...$new_hash --pretty=format:‘<li> %h %an $ai <a href=“https://bitbucket.org/api/commits/ view> commit </a> %s</li> ’ --reverse
curl -X POST -H 'Content-type: application/json' --data '{"text":"link to commit"}' https://hooks.slack.com/services/
Answer the question
In order to leave comments, you need to log in
It is not necessary to a file, you can directly to a variable
MYDATA=$(git rev-list --ancestry-path $old_hash...$new_hash --pretty=format:‘<li> %h %an $ai <a href=“https://bitbucket.org/api/commits/ view> commit </a> %s</li> ’ --reverse)
echo "I got the following result: $MYDATA"
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question