Sha256: cd0a7575df37dc941417408cf0d4edef0154a849c4973a1f40736d5a0f8846b9

Contents?: true

Size: 1.44 KB

Versions: 1019

Compression:

Stored size: 1.44 KB

Contents

module Fastlane
  module Actions
    class GitPullAction < Action
      def self.run(params)
        commands = []

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

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

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

      def self.description
        "Executes a simple git pull command"
      end

      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

      def self.authors
        ["KrauseFx", "JaviSoto"]
      end

      def self.is_supported?(platform)
        true
      end

      def self.example_code
        [
          'git_pull',
          'git_pull(only_tags: true) # only the tags, no commits'
        ]
      end

      def self.category
        :source_control
      end
    end
  end
end

Version data entries

1,019 entries across 1,019 versions & 2 rubygems

Version Path
fastlane-2.153.1 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.153.0 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.152.0 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.151.2 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.151.1 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.151.0 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.3 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.2 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.1 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0.rc7 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0.rc6 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0.rc5 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0.rc4 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0.rc3 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0.rc2 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.150.0.rc1 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.149.1 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.149.0 fastlane/lib/fastlane/actions/git_pull.rb
fastlane-2.148.1 fastlane/lib/fastlane/actions/git_pull.rb