class Fastlane::Actions::GitPullAction

Public Class Methods

authors() click to toggle source
# File fastlane/lib/fastlane/actions/git_pull.rb, line 33
def self.authors
  ["KrauseFx", "JaviSoto"]
end
available_options() click to toggle source
# File fastlane/lib/fastlane/actions/git_pull.rb, line 20
def self.available_options
  [
    FastlaneCore::ConfigItem.new(key: :only_tags,
                                 description: "Simply pull the tags, and not bring new commits to the current branch from the remote",
                                 is_string: false,
                                 optional: true,
                                 default_value: false,
                                 verify_block: proc do |value|
                                   UI.user_error!("Please pass a valid value for only_tags. Use one of the following: true, false") unless value.kind_of?(TrueClass) || value.kind_of?(FalseClass)
                                 end)
  ]
end
category() click to toggle source
# File fastlane/lib/fastlane/actions/git_pull.rb, line 48
def self.category
  :source_control
end
description() click to toggle source
# File fastlane/lib/fastlane/actions/git_pull.rb, line 16
def self.description
  "Executes a simple git pull command"
end
example_code() click to toggle source
# File fastlane/lib/fastlane/actions/git_pull.rb, line 41
def self.example_code
  [
    'git_pull',
    'git_pull(only_tags: true) # only the tags, no commits'
  ]
end
is_supported?(platform) click to toggle source
# File fastlane/lib/fastlane/actions/git_pull.rb, line 37
def self.is_supported?(platform)
  true
end
run(params) click to toggle source
# File fastlane/lib/fastlane/actions/git_pull.rb, line 4
def self.run(params)
  commands = []

  unless params[:only_tags]
    commands += ["git pull &&"]
  end

  commands += ["git fetch --tags"]

  Actions.sh(commands.join(' '))
end