Permalink
Browse files

Hoe support contributed by Kouhei Sutou.

  • Loading branch information...
1 parent 7176c61 commit 3c79ccec52dfa29f14b7d6a13dff0ebd912afc7c @ueno committed Sep 7, 2009
Showing with 45 additions and 41 deletions.
  1. +9 −6 MANIFEST → Manifest.txt
  2. +20 −14 README
  3. +15 −0 Rakefile
  4. +1 −0 lib/gpgme.rb
  5. +0 −21 ruby-gpgme.gemspec
@@ -1,15 +1,18 @@
-lib/gpgme.rb
-lib/gpgme/compat.rb
-lib/gpgme/constants.rb
COPYING
COPYING.LESSER
+Makefile
+Manifest.txt
README
+Rakefile
THANKS
-extconf.rb
-gpgme_n.c
+examples/edit.rb
examples/genkey.rb
examples/keylist.rb
examples/roundtrip.rb
examples/sign.rb
examples/verify.rb
-examples/edit.rb
+extconf.rb
+gpgme_n.c
+lib/gpgme.rb
+lib/gpgme/compat.rb
+lib/gpgme/constants.rb
View
@@ -1,14 +1,20 @@
-* What's this?
+= Ruby-GPGME
+
+* http://rubyforge.org/projects/ruby-gpgme/
+
+== Description
Ruby-GPGME is a Ruby language binding of GPGME (GnuPG Made Easy).
-* Requirements
+WRITE ME: More about Ruby-GPGME...
+
+== Requirements
-- Ruby 1.8 or later
-- GPGME 1.1.2 or later
-- gpg-agent (optional, but recommended)
+* Ruby 1.8 or later
+* GPGME 1.1.2 or later
+* gpg-agent (optional, but recommended)
-* Installation
+== Installation
$ gem install ruby-gpgme
@@ -18,44 +24,44 @@ or
$ make
$ make install
-* Examples
+== Examples
examples/genkey.rb Generate a key pair in your keyring.
examples/keylist.rb List your keyring like gpg --list-keys.
examples/roundtrip.rb Encrypt a plain text and then decrypt it.
examples/sign.rb Create a clear text signature.
examples/verify.rb Verify a clear text signature given from stdin.
-* API
+== API
Ruby-GPGME provides three levels of API. The highest level API is
close to the command line interface of GnuPG. The mid level API looks
object-oriented (or rubyish). The lowest level API is close to the C
interface of GPGME.
-** The highest level API
+=== The highest level API
For example, to create a cleartext signature of the plaintext from
stdin and write the result to stdout can be written as follows.
$ ruby -rgpgme -e 'GPGME.clearsign($stdin, $stdout)'
-** The mid level API
+=== The mid level API
The same example can be rewritten in the mid level API as follows.
- $ ruby -rgpgme -e <<End
+ $ ruby -rgpgme -e <<End
ctx = GPGME::Ctx.new
plain = GPGME::Data.from_io($stdin)
sig = GPGME::Data.from_io($stdout)
ctx.sign(plain, sig, GPGME::SIG_MODE_CLEAR)
End
-** The lowest level API
+=== The lowest level API
The same example can be rewritten in the lowest level API as follows.
- $ ruby -rgpgme -e <<End
+ $ ruby -rgpgme -e <<End
ret = Array.new
GPGME::gpgme_new(ret)
ctx = ret.shift
@@ -71,7 +77,7 @@ highest level API. However, if you are already familier with the C
interface of GPGME and want to control detailed behavior of GPGME, it
might be useful.
-* License
+== License
The library itself is licensed under LGPLv2.1+. See the file
COPYING.LESSER and each file for copyright and warranty information.
View
@@ -0,0 +1,15 @@
+# -*- ruby -*-
+
+require 'rubygems'
+require 'hoe'
+
+Hoe.spec("gpgme") do
+ self.rubyforge_name = "ruby-gpgme"
+ self.author = ['Daiki Ueno']
+ self.email = 'ueno@unixuser.org'
+ self.readme_file = "README"
+ self.changes = "TODO"
+ self.spec_extras = {
+ "extensions" => ["extconf.rb"],
+ }
+end
View
@@ -93,6 +93,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
=end
module GPGME
+ VERSION = "1.0.7"
end
require 'gpgme_n'
View
@@ -1,21 +0,0 @@
-Gem::Specification.new do |s|
- s.name = 'ruby-gpgme'
- s.version = '1.0.7'
- s.authors = ['Daiki Ueno']
- s.date = '2009-07-25'
- s.email = 'ueno@unixuser.org'
- s.extensions = ['extconf.rb']
- s.files = ['COPYING', 'COPYING.LESSER', 'MANIFEST', 'Makefile', 'README',
- 'THANKS', 'extconf.rb', 'gpgme_n.c', 'lib/gpgme.rb',
- 'lib/gpgme/compat.rb', 'lib/gpgme/constants.rb',
- 'examples/sign.rb', 'examples/genkey.rb', 'examples/keylist.rb',
- 'examples/verify.rb', 'examples/roundtrip.rb', 'examples/edit.rb']
- s.has_rdoc = true
- s.rubyforge_project = 'ruby-gpgme'
- s.homepage = 'http://rubyforge.org/projects/ruby-gpgme/'
- s.require_paths = ['lib']
- s.summary = 'Ruby binding of GPGME.'
-end
-
-
-

0 comments on commit 3c79cce

Please sign in to comment.