Any way to mark commits in git

0 votes
My work involves using git. Time and again test a commit to check if it is working fine and then mark such commits as release. Till now I've been branching to do this, but I have to do a lot of back and forth for it. is there any other way to mark some of my master releases.
May 3, 2018 in DevOps & Agile by Atul
• 10,240 points
957 views

1 answer to this question.

0 votes

You can try and use git tags.

Also add the following alias to ~/.gitconfig:

release = !git tag -a release-$(git tag -l "release-*"|wc -l|sed 's/ //g')-$(git symbolic-ref --short HEAD)-$(git rev-parse HEAD)

You will create an annotated tag in this form:

release-<release number>-<branch name>-<commit hash>
answered May 3, 2018 by DareDev
• 6,890 points

Related Questions In DevOps & Agile

0 votes
1 answer
+1 vote
2 answers
0 votes
1 answer

How to compare two branches in Git?

Hi@akhtar, You can use the git diff command ...READ MORE

answered Sep 4, 2020 in DevOps & Agile by MD
• 95,460 points
2,048 views
0 votes
1 answer
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,062 views
+2 votes
1 answer
+13 votes
2 answers
0 votes
1 answer

How to disable auto-restart task in TeamCity

There is a parameter which can be ...READ MORE

answered Apr 29, 2018 in DevOps & Agile by DareDev
• 6,890 points
1,819 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP