code: def git_tag(tag_name, push=False):
      
      with chdir(get_root()):
          result = run_command('git tag -a {} -m "{}"'.format(tag_name, tag_name), capture=True)
  
          if push:
              if result.code != 0:
                  return result
              return run_command('git push origin {}'.format(tag_name), capture=True)
  
          return result
docs: Tag the repo using an annotated tag.