Esempio n. 1
0
 def tag(cls, sign, name, message):
     command = ["git", "tag", name]
     if sign:
         command += ["-s"]
     if message:
         command += ["--message", message]
     subprocess.check_output(_command_args(command))
Esempio n. 2
0
 def tag(cls, sign, name, message):
     command = ["hg", "tag", name]
     if sign:
         raise MercurialDoesNotSupportSignedTagsException(
             "Mercurial does not support signed tags.")
     if message:
         command += ["--message", message]
     subprocess.check_output(_command_args(command))
Esempio n. 3
0
    def tag(cls, sign, name, message):
        """
        Create a tag of the new_version in VCS.

        If only name is given, bumpversion uses a lightweight tag.
        Otherwise, it utilizes an annotated tag.
        """
        command = ["git", "tag", name]
        if sign:
            command += ["--sign"]
        if message:
            command += ["--message", message]
        subprocess.check_output(_command_args(command))
Esempio n. 4
0
 def add_path(cls, path):
     subprocess.check_output(_command_args(["git", "add", "--update", path]))