From 6b35bbbe1a9909c737c1cd53edcfc47af0ad063c Mon Sep 17 00:00:00 2001 From: elijah Date: Mon, 4 May 2015 16:17:01 -0700 Subject: make gpgme optional --- Gemfile | 30 ------------------------------ leap_cli.gemspec | 3 ++- lib/leap_cli/commands/user.rb | 2 +- 3 files changed, 3 insertions(+), 32 deletions(-) diff --git a/Gemfile b/Gemfile index fe076b0..06618ce 100644 --- a/Gemfile +++ b/Gemfile @@ -1,33 +1,3 @@ source 'https://rubygems.org' gemspec -# # -# # Specify support gems used that we might also develop locally. -# # -# # Available options: -# # -# # :dev_path - the development path of the gem. this path is used if running in 'development mode'. -# # -# # :vendor_path - where this gem is vendored. this path is used if it exists and we are running in 'production mode' -# # -# development_gems = { -# 'supply_drop' => {:dev_path => '../gems/supply_drop', :vendor_path => 'vendor/supply_drop'}, -# 'certificate_authority' => {:dev_path => '../gems/certificate_authority', :vendor_path => 'vendor/certificate_authority'} -# } - -# # -# # A little bit of code to magically pick the correct gem -# # - -# mode = :production - -# gem_root = File.dirname(__FILE__) -# path_key = mode == :development ? :dev_path : :vendor_path -# development_gems.each do |gem_name, options| -# path = File.expand_path(options[path_key], gem_root) -# if File.directory?(path) -# gem gem_name, :path => path -# else -# gem gem_name -# end -# end diff --git a/leap_cli.gemspec b/leap_cli.gemspec index e9215fb..b9bad48 100644 --- a/leap_cli.gemspec +++ b/leap_cli.gemspec @@ -64,7 +64,8 @@ spec = Gem::Specification.new do |s| # crypto gems #s.add_runtime_dependency('certificate_authority', '>= 0.2.0') # ^^ currently vendored - s.add_runtime_dependency('gpgme') # not essential, but used for some minor stuff in adding sysadmins + # s.add_runtime_dependency('gpgme') # << does not build on debian jessie, so now optional. + # also, there is a ruby-gpgme package anyway. # misc gems s.add_runtime_dependency('ya2yaml') # pure ruby yaml, so we can better control output. see https://github.com/afunai/ya2yaml diff --git a/lib/leap_cli/commands/user.rb b/lib/leap_cli/commands/user.rb index 6c33878..480e9a9 100644 --- a/lib/leap_cli/commands/user.rb +++ b/lib/leap_cli/commands/user.rb @@ -100,9 +100,9 @@ module LeapCli # def pick_pgp_key begin - return unless `which gpg`.strip.any? require 'gpgme' rescue LoadError + log "Skipping OpenPGP setup because gpgme is not installed." return end -- cgit v1.2.3