How to automate git tag creation after a successful build in Xcode Cloud?

Does anyone have any recommendations for the "best" way to add a tag to one's git repo after a successful build in Xcode Cloud?

Currently I'm creating the tag myself locally after I see that a build has passed, but I'd like that to be automatic.

How to automate git tag creation after a successful build in Xcode Cloud?
 
 
Q