Class: Fastlane::Actions::IosClearIntermediateTagsAction
- Inherits:
-
Action
- Object
- Action
- Fastlane::Actions::IosClearIntermediateTagsAction
- Defined in:
- lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb
Documentation collapse
- .authors ⇒ Object
- .available_options ⇒ Object
- .category ⇒ Object
- .deprecated_notes ⇒ Object
- .description ⇒ Object
- .details ⇒ Object
- .is_supported?(platform) ⇒ Boolean
- .output ⇒ Object
- .return_value ⇒ Object
Class Method Summary collapse
Class Method Details
.authors ⇒ Object
63 64 65 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 63 def self. ['Automattic'] end |
.available_options ⇒ Object
38 39 40 41 42 43 44 45 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 38 def self. [ FastlaneCore::ConfigItem.new(key: :version, env_name: 'FL_IOS_CLEAN_INTERMEDIATE_TAGS_VERSION', description: 'The version of the tags to clear', type: String), ] end |
.category ⇒ Object
53 54 55 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 53 def self.category :deprecated end |
.deprecated_notes ⇒ Object
57 58 59 60 61 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 57 def self.deprecated_notes "This action is deprecated as we don't believe it's currently in use in our projects. However, just to be sure that it's not in use, we decided to deprecate it first. If you believe that this is a mistake, please let us know on Slack." end |
.description ⇒ Object
30 31 32 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 30 def self.description '(DEPRECATED) Cleans all the intermediate tags for the given version' end |
.details ⇒ Object
34 35 36 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 34 def self.details '(DEPRECATED) Cleans all the intermediate tags for the given version' end |
.is_supported?(platform) ⇒ Boolean
67 68 69 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 67 def self.is_supported?(platform) [:ios, :mac].include?(platform) end |
.output ⇒ Object
47 48 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 47 def self.output end |
.return_value ⇒ Object
50 51 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 50 def self.return_value end |
.run(params) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_clear_intermediate_tags.rb', line 4 def self.run(params) return unless UI.confirm("#{deprecated_notes} Would you like to continue with the action?") UI.("Deleting tags for version: #{params[:version]}") require_relative '../../helper/git_helper' # Download all the remote tags prior to starting – that way we don't miss any on the server Fastlane::Helper::GitHelper. # Delete 4-parts version names starting with our version number parts = params[:version].split('.') pattern = parts.fill('*', parts.length...4).join('.') # "1.2.*.*" or "1.2.3.*" = Fastlane::Helper::GitHelper.(matching: pattern) tag_count = .count return unless tag_count.positive? && UI.confirm("Are you sure you want to delete #{tag_count} tags?") Fastlane::Helper::GitHelper.(, delete_on_remote: true) end |