Class: Fastlane::Actions::RemoveGitTagAction
- Inherits:
-
Action
- Object
- Action
- Fastlane::Actions::RemoveGitTagAction
- Defined in:
- lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb
Overview
Adds a git tag to the current commit
Class Method Summary collapse
- .authors ⇒ Object
- .available_options ⇒ Object
- .category ⇒ Object
- .description ⇒ Object
- .details ⇒ Object
- .example_code ⇒ Object
- .is_supported?(platform) ⇒ Boolean
- .run(options) ⇒ Object
Class Method Details
.authors ⇒ Object
55 56 57 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 55 def self. ["Marker Digital"] end |
.available_options ⇒ Object
36 37 38 39 40 41 42 43 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 36 def self. [ FastlaneCore::ConfigItem.new(key: :tag, env_name: "FL_GIT_TAG_TAG", description: "Define your own tag text. This will replace all other parameters", optional: true) ] end |
.category ⇒ Object
51 52 53 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 51 def self.category :source_control end |
.description ⇒ Object
25 26 27 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 25 def self.description "This will remove a tag from the remote repository" end |
.details ⇒ Object
29 30 31 32 33 34 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 29 def self.details [ "This will automatically remove a tag from the remote repository, where:", "- `tag` is the tag name" ].join("\n") end |
.example_code ⇒ Object
45 46 47 48 49 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 45 def self.example_code [ 'remove_git_tag(tag: "Beta")' ] end |
.is_supported?(platform) ⇒ Boolean
59 60 61 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 59 def self.is_supported?(platform) true end |
.run(options) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/fastlane/plugin/remove_git_tag/actions/remove_git_tag_action.rb', line 9 def self.run() # lane name in lane_context could be nil because you can just call $fastlane add_git_tag which has no context lane_name = Actions.lane_context[Actions::SharedValues::LANE_NAME].to_s.delete(' ') # no spaces allowed tag = [:tag] cmd = ["git tag -d #{tag.shellescape}"] UI.("Removing remote git tag '#{tag}' 🎯.") Actions.sh(cmd.join(' ')) cmd = ["git push origin :refs/tags/#{tag.shellescape}"] UI.("Removing remote git tag '#{tag}' 🎯.") Actions.sh(cmd.join(' ')) end |