ruby_gpg 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ddc082532dfd54e87fcf5397f812a356cb6e2c88
4
+ data.tar.gz: da78a488b46f410a1a0065e928d8c947899c6ff0
5
+ SHA512:
6
+ metadata.gz: 34c146085c41bf2bcf1dd01da8ab47b0c2408879d95d0d47a03b2e7897252ebe3cb35311c1bc1d0ac513481c49e90e95b45b6a074b86d6713d764e3a914f68f1
7
+ data.tar.gz: 82e35ad90b5912635453b6608362558730769b2d5e3e417207d556c9290dc3c32ab31d0ce47ff9e78cc082fa5ca3154b2e2610220e96aa50c51e02433bdff795
data/.gitignore CHANGED
@@ -20,6 +20,7 @@ pkg
20
20
  tmp
21
21
  doc
22
22
  .yardoc
23
+ Gemfile.lock
23
24
 
24
25
  ## PROJECT::SPECIFIC
25
26
  test_keys/random_seed
data/CHANGELOG.markdown CHANGED
@@ -1,3 +1,7 @@
1
+ # v0.3.1 (2014-02-27)
2
+
3
+ * Make it work in jruby (2916bbba92d1b9a4fd2847883ed27c77617295a5)
4
+
1
5
  # v0.3.0 (2010-07-16)
2
6
 
3
7
  In which other people do my work for me...
@@ -5,7 +9,7 @@ In which other people do my work for me...
5
9
  ## Thanks to Scott and Divya of [gitcaps](http://github.com/gitcapps) for:
6
10
 
7
11
  * New `RubyGpg.encrypt_string` method.
8
- * Option to allow decryption of ascii armored files (*.asc).
12
+ * Option to allow decryption of ascii armored files (`*.asc`).
9
13
  * Option to specify output filename.
10
14
 
11
15
  # v0.2.0 (2010-03-17)
data/README.markdown CHANGED
@@ -29,7 +29,9 @@ For more details, see the
29
29
 
30
30
  ## Credits
31
31
 
32
- Scott and Divya of [gitcaps](http://github.com/gitcapps) added some sorely
32
+ * [Raphaël Pinson](https://github.com/raphink) modernized things and added some
33
+ features. Thanks.
34
+ * Scott and Divya of [gitcaps](http://github.com/gitcapps) added some sorely
33
35
  missing features. Thanks, guys.
34
36
 
35
37
  ## Copyright
data/Rakefile CHANGED
@@ -1,53 +1,27 @@
1
1
  require 'rubygems'
2
2
  require 'rake'
3
3
 
4
- begin
5
- require 'jeweler'
6
- Jeweler::Tasks.new do |gem|
7
- gem.name = "ruby_gpg"
8
- gem.summary = %Q{Ruby wrapper for the gpg binary}
9
- gem.description = %Q{Ruby wrapper for the gpg binary}
10
- gem.email = "justin@megablaix.com"
11
- gem.homepage = "http://github.com/blaix/ruby_gpg"
12
- gem.authors = ["Justin Blake"]
13
- gem.add_development_dependency "rspec", ">= 1.2.9"
14
- gem.add_development_dependency "yard", ">= 0"
15
- gem.add_development_dependency "cucumber", ">= 0"
16
- gem.add_development_dependency "mocha", ">= 0.9.8"
17
- # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
18
- end
19
- Jeweler::GemcutterTasks.new
20
- rescue LoadError
21
- puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
22
- end
23
-
24
- require 'spec/rake/spectask'
25
- Spec::Rake::SpecTask.new(:spec) do |spec|
26
- spec.libs << 'lib' << 'spec'
27
- spec.spec_files = FileList['spec/**/*_spec.rb']
4
+ require 'rspec/core/rake_task'
5
+ RSpec::Core::RakeTask.new(:spec) do |spec|
6
+ spec.pattern = 'spec/**/*_spec.rb'
28
7
  end
29
8
 
30
9
  namespace :spec do
31
- Spec::Rake::SpecTask.new(:doc) do |spec|
32
- spec.libs << 'lib' << 'spec'
33
- spec.spec_files = FileList['spec/**/*_spec.rb']
10
+ RSpec::Core::RakeTask.new(:doc) do |spec|
11
+ spec.pattern = 'spec/**/*_spec.rb'
34
12
  spec.spec_opts << '--format specdoc'
35
13
  end
36
14
  end
37
15
 
38
- Spec::Rake::SpecTask.new(:rcov) do |spec|
39
- spec.libs << 'lib' << 'spec'
16
+ RSpec::Core::RakeTask.new(:rcov) do |spec|
40
17
  spec.pattern = 'spec/**/*_spec.rb'
41
18
  spec.rcov = true
42
19
  end
43
20
 
44
- task :spec => :check_dependencies
45
-
46
21
  begin
47
22
  require 'cucumber/rake/task'
48
23
  Cucumber::Rake::Task.new(:features)
49
24
 
50
- task :features => :check_dependencies
51
25
  rescue LoadError
52
26
  task :features do
53
27
  abort "Cucumber is not available. In order to run features, you must: sudo gem install cucumber"
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.0
1
+ 0.3.1
@@ -20,7 +20,7 @@ Given /^I read the file "([^\"]*)" to a string$/ do |filename|
20
20
  end
21
21
 
22
22
  Given /^the string should not be "([^\"]*)"$/ do |string|
23
- @string.strip.should_not == string.strip
23
+ @string.encode('UTF-8', 'binary', invalid: :replace, undef: :replace, replace: '').strip.should_not == string.strip
24
24
  end
25
25
 
26
26
  When /^I encrypt the file "([^\"]*)" for "([^\"]*)"$/ do |filename, recipient|
@@ -1,9 +1,10 @@
1
1
  $LOAD_PATH.unshift(File.dirname(__FILE__) + '/../../lib')
2
2
  require 'ruby_gpg'
3
3
 
4
- require 'spec/expectations'
4
+ require 'rspec/expectations'
5
5
 
6
- TMP_PATH = File.dirname(__FILE__) + '/../../tmp'
6
+ require 'tmpdir'
7
+ TMP_PATH = Dir.mktmpdir('cucumber')
7
8
 
8
9
  class Object
9
10
  def true?
data/lib/ruby_gpg.rb CHANGED
@@ -58,7 +58,7 @@ module RubyGpg
58
58
  output = ""
59
59
  Open3.popen3(command) do |stdin, stdout, stderr|
60
60
  stdin.write(input) if input
61
- stdin.close_write
61
+ stdin.close
62
62
  output << stdout.read
63
63
  error = stderr.read
64
64
  if error && !error.empty?
data/ruby_gpg.gemspec CHANGED
@@ -1,11 +1,8 @@
1
- # Generated by jeweler
2
- # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
4
1
  # -*- encoding: utf-8 -*-
5
2
 
6
3
  Gem::Specification.new do |s|
7
4
  s.name = %q{ruby_gpg}
8
- s.version = "0.3.0"
5
+ s.version = "0.3.1"
9
6
 
10
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
8
  s.authors = ["Justin Blake"]
@@ -49,26 +46,10 @@ Gem::Specification.new do |s|
49
46
  "spec/spec_helper.rb"
50
47
  ]
51
48
 
52
- if s.respond_to? :specification_version then
53
- current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
54
- s.specification_version = 3
55
-
56
- if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
57
- s.add_development_dependency(%q<rspec>, [">= 1.2.9"])
58
- s.add_development_dependency(%q<yard>, [">= 0"])
59
- s.add_development_dependency(%q<cucumber>, [">= 0"])
60
- s.add_development_dependency(%q<mocha>, [">= 0.9.8"])
61
- else
62
- s.add_dependency(%q<rspec>, [">= 1.2.9"])
63
- s.add_dependency(%q<yard>, [">= 0"])
64
- s.add_dependency(%q<cucumber>, [">= 0"])
65
- s.add_dependency(%q<mocha>, [">= 0.9.8"])
66
- end
67
- else
68
- s.add_dependency(%q<rspec>, [">= 1.2.9"])
69
- s.add_dependency(%q<yard>, [">= 0"])
70
- s.add_dependency(%q<cucumber>, [">= 0"])
71
- s.add_dependency(%q<mocha>, [">= 0.9.8"])
72
- end
49
+ s.add_development_dependency(%q<rake>, ["~> 10.0"])
50
+ s.add_development_dependency(%q<rspec>, ["~> 2.99.0"])
51
+ s.add_development_dependency(%q<yard>, [">= 0"])
52
+ s.add_development_dependency(%q<cucumber>, [">= 0"])
53
+ s.add_development_dependency(%q<mocha>, [">= 1.1.0"])
73
54
  end
74
55
 
@@ -4,9 +4,12 @@ describe "RubyGpg" do
4
4
  def expect_command_to_match(part_of_command)
5
5
  Open3.expects(:popen3).with do |command|
6
6
  case part_of_command
7
- when Regexp: command =~ part_of_command
8
- when String: command.include?(part_of_command)
9
- else raise "Can't match that"
7
+ when Regexp
8
+ command =~ part_of_command
9
+ when String
10
+ command.include?(part_of_command)
11
+ else
12
+ raise "Can't match that"
10
13
  end
11
14
  end
12
15
  end
data/spec/spec_helper.rb CHANGED
@@ -1,9 +1,8 @@
1
1
  $LOAD_PATH.unshift(File.dirname(__FILE__))
2
2
  $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
3
3
  require 'ruby_gpg'
4
- require 'spec'
5
- require 'spec/autorun'
4
+ require 'rspec'
6
5
 
7
- Spec::Runner.configure do |config|
8
- config.mock_with :mocha
6
+ RSpec.configure do |config|
7
+ config.mock_framework = :mocha
9
8
  end
Binary file
metadata CHANGED
@@ -1,69 +1,95 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: ruby_gpg
3
- version: !ruby/object:Gem::Version
4
- version: 0.3.0
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.3.1
5
5
  platform: ruby
6
- authors:
6
+ authors:
7
7
  - Justin Blake
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
-
12
- date: 2010-07-16 00:00:00 -04:00
13
- default_executable:
14
- dependencies:
15
- - !ruby/object:Gem::Dependency
11
+ date: 2010-07-16 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: rake
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '10.0'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '10.0'
27
+ - !ruby/object:Gem::Dependency
16
28
  name: rspec
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: 2.99.0
17
34
  type: :development
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
20
- requirements:
21
- - - ">="
22
- - !ruby/object:Gem::Version
23
- version: 1.2.9
24
- version:
25
- - !ruby/object:Gem::Dependency
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: 2.99.0
41
+ - !ruby/object:Gem::Dependency
26
42
  name: yard
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
27
48
  type: :development
28
- version_requirement:
29
- version_requirements: !ruby/object:Gem::Requirement
30
- requirements:
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
31
52
  - - ">="
32
- - !ruby/object:Gem::Version
33
- version: "0"
34
- version:
35
- - !ruby/object:Gem::Dependency
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
36
56
  name: cucumber
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
37
62
  type: :development
38
- version_requirement:
39
- version_requirements: !ruby/object:Gem::Requirement
40
- requirements:
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
41
66
  - - ">="
42
- - !ruby/object:Gem::Version
43
- version: "0"
44
- version:
45
- - !ruby/object:Gem::Dependency
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
46
70
  name: mocha
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: 1.1.0
47
76
  type: :development
48
- version_requirement:
49
- version_requirements: !ruby/object:Gem::Requirement
50
- requirements:
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
51
80
  - - ">="
52
- - !ruby/object:Gem::Version
53
- version: 0.9.8
54
- version:
81
+ - !ruby/object:Gem::Version
82
+ version: 1.1.0
55
83
  description: Ruby wrapper for the gpg binary
56
84
  email: justin@megablaix.com
57
85
  executables: []
58
-
59
86
  extensions: []
60
-
61
- extra_rdoc_files:
87
+ extra_rdoc_files:
62
88
  - LICENSE
63
89
  - README.markdown
64
- files:
65
- - .autotest
66
- - .gitignore
90
+ files:
91
+ - ".autotest"
92
+ - ".gitignore"
67
93
  - CHANGELOG.markdown
68
94
  - LICENSE
69
95
  - README.markdown
@@ -83,34 +109,31 @@ files:
83
109
  - test_keys/pubring.gpg
84
110
  - test_keys/secring.gpg
85
111
  - test_keys/trustdb.gpg
86
- has_rdoc: true
87
112
  homepage: http://github.com/blaix/ruby_gpg
88
113
  licenses: []
89
-
114
+ metadata: {}
90
115
  post_install_message:
91
- rdoc_options:
92
- - --charset=UTF-8
93
- require_paths:
116
+ rdoc_options:
117
+ - "--charset=UTF-8"
118
+ require_paths:
94
119
  - lib
95
- required_ruby_version: !ruby/object:Gem::Requirement
96
- requirements:
120
+ required_ruby_version: !ruby/object:Gem::Requirement
121
+ requirements:
97
122
  - - ">="
98
- - !ruby/object:Gem::Version
99
- version: "0"
100
- version:
101
- required_rubygems_version: !ruby/object:Gem::Requirement
102
- requirements:
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ required_rubygems_version: !ruby/object:Gem::Requirement
126
+ requirements:
103
127
  - - ">="
104
- - !ruby/object:Gem::Version
105
- version: "0"
106
- version:
128
+ - !ruby/object:Gem::Version
129
+ version: '0'
107
130
  requirements: []
108
-
109
131
  rubyforge_project:
110
- rubygems_version: 1.3.5
132
+ rubygems_version: 2.4.6
111
133
  signing_key:
112
- specification_version: 3
134
+ specification_version: 4
113
135
  summary: Ruby wrapper for the gpg binary
114
- test_files:
136
+ test_files:
115
137
  - spec/ruby_gpg_spec.rb
116
138
  - spec/spec_helper.rb
139
+ has_rdoc: