Sha256: d025d573b377baa7179f52ab03c2ef882d14a250d2fd68c4f5ef6d6c0a3b8c53

Contents?: true

Size: 1.48 KB

Versions: 10

Compression:

Stored size: 1.48 KB

Contents

require 'commander'
require 'fastlane/version'

HighLine.track_eof = false

module Cert
  class CommandsGenerator
    include Commander::Methods

    def self.start
      self.new.run
    end

    def run
      program :name, 'cert'
      program :version, Fastlane::VERSION
      program :description, 'CLI for \'cert\' - Create new iOS code signing certificates'
      program :help, 'Author', 'Felix Krause <cert@krausefx.com>'
      program :help, 'Website', 'https://fastlane.tools'
      program :help, 'GitHub', 'https://github.com/fastlane/cert'
      program :help_formatter, :compact

      global_option('--verbose') { $verbose = true }

      FastlaneCore::CommanderGenerator.new.generate(Cert::Options.available_options)

      command :create do |c|
        c.syntax = 'fastlane cert create'
        c.description = 'Create new iOS code signing certificates'

        c.action do |args, options|
          Cert.config = FastlaneCore::Configuration.create(Cert::Options.available_options, options.__hash__)
          Cert::Runner.new.launch
        end
      end

      command :revoke_expired do |c|
        c.syntax = 'fastlane cert revoke_expired'
        c.description = 'Revoke expired iOS code signing certificates'

        c.action do |args, options|
          Cert.config = FastlaneCore::Configuration.create(Cert::Options.available_options, options.__hash__)
          Cert::Runner.new.revoke_expired_certs!
        end
      end

      default_command :create

      run!
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
fastlane-2.14.2 cert/lib/cert/commands_generator.rb
fastlane-2.14.1 cert/lib/cert/commands_generator.rb
fastlane-2.14.0 cert/lib/cert/commands_generator.rb
fastlane-2.13.0 cert/lib/cert/commands_generator.rb
fastlane-2.12.0 cert/lib/cert/commands_generator.rb
fastlane-2.11.0 cert/lib/cert/commands_generator.rb
fastlane-2.10.0 cert/lib/cert/commands_generator.rb
fastlane-2.9.0 cert/lib/cert/commands_generator.rb
fastlane-2.8.0 cert/lib/cert/commands_generator.rb
fastlane-2.7.0 cert/lib/cert/commands_generator.rb