Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can we force git to always add tags as annotated

Tags:

git

I need to force every new tag to be annotated tag. I need to force it to every user without telling them to do something special. I tried alias for tag to be "tag -a -m ''", but it doesn't work.

like image 459
Kamil.Khoury Avatar asked Dec 12 '25 06:12

Kamil.Khoury


1 Answers

In .gitconfig, you can create an alias under a different name:

[alias]
    atag = tag -a -m ""

Then git atag creates an annotated tag. Not exactly elegant, but better than having to pass the -m each time.

like image 150
Jason R. Coombs Avatar answered Dec 14 '25 18:12

Jason R. Coombs