Sha256: 824c72ce6c3cce0ae77d3383fc804f434eeb9766d1c06d1d3fdaf152f256650e

Contents?: true

Size: 1013 Bytes

Versions: 6

Compression:

Stored size: 1013 Bytes

Contents

module Fastlane
  module Actions
    module SharedValues
      CERT_FILE_PATH = :CERT_FILE_PATH
      CERT_CERTIFICATE_ID = :CERT_CERTIFICATE_ID
    end

    class CertAction
      def self.run(params)
        require 'cert'

        return if Helper.test?

        Dir.chdir(FastlaneFolder.path || Dir.pwd) do
          # This should be executed in the fastlane folder

          Cert::CertRunner.run
          cert_file_path = ENV["CER_FILE_PATH"]
          certificate_id = ENV["CER_CERTIFICATE_ID"]
          Actions.lane_context[SharedValues::CERT_FILE_PATH] = cert_file_path
          Actions.lane_context[SharedValues::CERT_CERTIFICATE_ID] = certificate_id

          installed = Cert::CertChecker.is_installed?cert_file_path
          raise "Could not find the newly generated certificate installed" unless installed

          Helper.log.info("Use signing certificate '#{certificate_id}' from now on!".green)

          ENV["SIGH_CERTIFICATE_ID"] = certificate_id
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
fastlane-0.1.17 lib/fastlane/actions/cert.rb
fastlane-0.1.16 lib/fastlane/actions/cert.rb
fastlane-0.1.15 lib/fastlane/actions/cert.rb
fastlane-0.1.14 lib/fastlane/actions/cert.rb
fastlane-0.1.13 lib/fastlane/actions/cert.rb
fastlane-0.1.12 lib/fastlane/actions/cert.rb