Sha256: 9110f8db003331ebb93731e7d2b750cb7fac81da48671bdafedbfc69422df7a5

Contents?: true

Size: 1.08 KB

Versions: 3

Compression:

Stored size: 1.08 KB

Contents

require_relative 'app_identifier_guesser'

module FastlaneCore
  class ActionCompletionStatus
    SUCCESS = 'success'
    FAILED = 'failed' # fastlane crashes unrelated to user_error!
    USER_ERROR = 'user_error' # Anytime a user_error! is triggered
    INTERRUPTED = 'interrupted'
  end

  class ActionCompletionContext
    attr_accessor :p_hash
    attr_accessor :action_name
    attr_accessor :status
    attr_accessor :fastlane_client_language

    def initialize(p_hash: nil, action_name: nil, status: nil, fastlane_client_language: nil)
      @p_hash = p_hash
      @action_name = action_name
      @status = status
      @fastlane_client_language = fastlane_client_language
    end

    def self.context_for_action_name(action_name, fastlane_client_language: :ruby, args: nil, status: nil)
      app_id_guesser = FastlaneCore::AppIdentifierGuesser.new(args: args)
      return self.new(
        action_name: action_name,
        p_hash: app_id_guesser.p_hash,
        status: status,
        fastlane_client_language: fastlane_client_language
      )
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fastlane_hotfix-2.165.1 fastlane_core/lib/fastlane_core/analytics/action_completion_context.rb
fastlane_hotfix-2.165.0 fastlane_core/lib/fastlane_core/analytics/action_completion_context.rb
fastlane_hotfix-2.187.0 fastlane_core/lib/fastlane_core/analytics/action_completion_context.rb