Class: Git::Commands::Tag::Delete Private

Inherits:
Base
  • Object
show all
Defined in:
lib/git/commands/tag/delete.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Note:

arguments block audited against https://git-scm.com/docs/git-tag/2.53.0

Implements the git tag --delete command for deleting tags

This command deletes one or more tag references.

Examples:

Delete a single tag

delete = Git::Commands::Tag::Delete.new(execution_context)
delete.call('v1.0.0')

Delete multiple tags

delete = Git::Commands::Tag::Delete.new(execution_context)
delete.call('v1.0.0', 'v2.0.0')

See Also:

Instance Method Summary collapse

Methods inherited from Base

allow_exit_status, arguments, #initialize, requires_git_version, skip_version_validation

Constructor Details

This class inherits a constructor from Git::Commands::Base

Instance Method Details

#call(*tagname) ⇒ Git::CommandLineResult

Execute the git tag --delete command to delete one or more tags.

Parameters:

  • tagname (Array<String>)

    one or more tag names to delete

Returns:

Raises:

  • (ArgumentError)

    if no tag names are provided or unsupported options are provided

  • (Git::FailedError)

    if git exits outside the allowed range (exit code > 1)



# File 'lib/git/commands/tag/delete.rb', line 38