Sha256: 35025ee06a1019bacca6ae167ff053083bb39476f3a72506fdbb2d8c25d92ba9

Contents?: true

Size: 1.65 KB

Versions: 82

Compression:

Stored size: 1.65 KB

Contents

module Fastlane
  module Actions
    module SharedValues
    end

    class DotgpgEnvironmentAction < Action
      def self.run(options)
        Actions.verify_gem!('dotgpg')
        require 'dotgpg/environment'

        UI.message("Reading secrets from #{options[:dotgpg_file]}")
        Dotgpg::Environment.new(options[:dotgpg_file]).apply
      end

      def self.description
        "Reads in production secrets set in a dotgpg file and puts them in ENV"
      end

      def self.details
        "More information about dotgpg can be found at https://github.com/ConradIrwin/dotgpg"
      end

      def self.available_options
        [
          FastlaneCore::ConfigItem.new(key: :dotgpg_file,
                                       env_name: "DOTGPG_FILE",
                                       description: "Path to your gpg file",
                                       code_gen_sensitive: true,
                                       default_value: Dir["dotgpg/*.gpg"].last,
                                       default_value_dynamic: true,
                                       optional: false,
                                       verify_block: proc do |value|
                                         UI.user_error!("Dotgpg file '#{File.expand_path(value)}' not found") unless File.exist?(value)
                                       end)
        ]
      end

      def self.authors
        ["simonlevy5"]
      end

      def self.example_code
        [
          "dotgpg_environment(dotgpg_file: './path/to/gpgfile')"
        ]
      end

      def self.category
        :misc
      end

      def self.is_supported?(platform)
        true
      end
    end
  end
end

Version data entries

82 entries across 82 versions & 1 rubygems

Version Path
fastlane-2.85.0.beta.20180308050114 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.85.0.beta.20180307050101 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.85.0.beta.20180306050019 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.85.0.beta.20180305050037 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.85.0.beta.20180304050031 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.85.0.beta.20180303050048 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.85.0.beta.20180302050035 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.84.0 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.84.0.beta.20180301050048 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.84.0.beta.20180228050122 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.84.0.beta.20180227050054 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.83.0 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.83.0.beta.20180226050016 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.83.0.beta.20180225050035 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.83.0.beta.20180224050047 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.82.0 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.82.0.beta.20180223010003 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.82.0.beta.20180222010003 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.82.0.beta.20180221010003 fastlane/lib/fastlane/actions/dotgpg_environment.rb
fastlane-2.82.0.beta.20180220010002 fastlane/lib/fastlane/actions/dotgpg_environment.rb