Making this all work with Hoe.
History has been collapsed Manifest is modern. Textile README is changed to Markdown because Hoe complains less.
This commit is contained in:
parent
427c7972b4
commit
b3f5aff852
8
.gitignore
vendored
8
.gitignore
vendored
|
@ -1,2 +1,8 @@
|
|||
pkg/
|
||||
*.gemspec
|
||||
*.swp
|
||||
html/
|
||||
doc/
|
||||
publish/
|
||||
coverage/
|
||||
coverage.info
|
||||
.rake_tasks~
|
||||
|
|
|
@ -1,11 +1,8 @@
|
|||
=== Net::LDAP 0.1.0 / 2010-03-08
|
||||
|
||||
* Ruby 1.9 support. Should now run with rubies starting 1.8.2 upwards.
|
||||
|
||||
* New maintainers, new project repository location. Please see the README.txt.
|
||||
|
||||
=== Net::LDAP 0.0.5 / 2009-03-xx
|
||||
|
||||
* 13 minor enhancements:
|
||||
* Added Net::LDAP::Entry#to_ldif
|
||||
* Supported rootDSE searches with a new API.
|
||||
|
@ -27,7 +24,6 @@
|
|||
* Added support for binary values in Net::LDAP::Entry LDIF conversions
|
||||
and marshalling.
|
||||
* Migrated to 'hoe' as the new project droid.
|
||||
|
||||
* 14 bugs fixed:
|
||||
* Silenced some annoying warnings in filter.rb. Thanks to "barjunk"
|
||||
for pointing this out.
|
||||
|
@ -53,7 +49,6 @@
|
|||
* Minor bug fixes here and there.
|
||||
|
||||
=== Net::LDAP 0.0.4 / 2006-08-15
|
||||
|
||||
* Undeprecated Net::LDAP#modify. Thanks to Justin Forder for
|
||||
providing the rationale for this.
|
||||
* Added a much-expanded set of special characters to the parser
|
||||
|
@ -66,12 +61,10 @@
|
|||
called more than one on a given Net::LDAP object.
|
||||
|
||||
=== Net::LDAP 0.0.3 / 2006-07-26
|
||||
|
||||
* Added simple TLS encryption.
|
||||
Thanks to Garett Shulman for suggestions and for helping test.
|
||||
|
||||
=== Net::LDAP 0.0.2 / 2006-07-12
|
||||
|
||||
* Fixed malformation in distro tarball and gem.
|
||||
* Improved documentation.
|
||||
* Supported "paged search control."
|
||||
|
@ -86,7 +79,6 @@
|
|||
* Added support for RFC-2254 filter syntax.
|
||||
|
||||
=== Net::LDAP 0.0.1 / 2006-05-01
|
||||
|
||||
* Initial release.
|
||||
* Client functionality is near-complete, although the APIs
|
||||
are not guaranteed and may change depending on feedback
|
||||
|
|
5
LICENSE
5
LICENSE
|
@ -1,6 +1,7 @@
|
|||
Net::LDAP is copyrighted free software by Francis Cianfrocca
|
||||
<garbagecat10@gmail.com>. You can redistribute it and/or modify it under either
|
||||
the terms of the GPL (see the file COPYING), or the conditions below:
|
||||
<garbagecat10@gmail.com> and other contributors. You can redistribute it and/or
|
||||
modify it under either the terms of the GPL (see the file COPYING), or the
|
||||
conditions below:
|
||||
|
||||
1. You may make and give away verbatim copies of the source form of the
|
||||
software without restriction, provided that you duplicate all of the
|
||||
|
|
39
Manifest.txt
39
Manifest.txt
|
@ -0,0 +1,39 @@
|
|||
COPYING
|
||||
History.txt
|
||||
LICENSE
|
||||
Manifest.txt
|
||||
README.markdown
|
||||
README.textile
|
||||
Rakefile
|
||||
lib/net.rb
|
||||
lib/net/ber.rb
|
||||
lib/net/ber/ber_parser.rb
|
||||
lib/net/ldap.rb
|
||||
lib/net/ldap/core_ext/all.rb
|
||||
lib/net/ldap/core_ext/array.rb
|
||||
lib/net/ldap/core_ext/bignum.rb
|
||||
lib/net/ldap/core_ext/false_class.rb
|
||||
lib/net/ldap/core_ext/fixnum.rb
|
||||
lib/net/ldap/core_ext/string.rb
|
||||
lib/net/ldap/core_ext/true_class.rb
|
||||
lib/net/ldap/dataset.rb
|
||||
lib/net/ldap/entry.rb
|
||||
lib/net/ldap/filter.rb
|
||||
lib/net/ldap/pdu.rb
|
||||
lib/net/ldap/psw.rb
|
||||
lib/net/ldif.rb
|
||||
lib/net/snmp.rb
|
||||
spec/integration/ssl_ber_spec.rb
|
||||
spec/spec.opts
|
||||
spec/spec_helper.rb
|
||||
spec/unit/ber/ber_spec.rb
|
||||
test/common.rb
|
||||
test/test_ber.rb
|
||||
test/test_entry.rb
|
||||
test/test_filter.rb
|
||||
test/test_ldif.rb
|
||||
test/test_password.rb
|
||||
test/test_snmp.rb
|
||||
test/testdata.ldif
|
||||
testserver/ldapserver.rb
|
||||
testserver/testdata.ldif
|
|
@ -1,18 +1,20 @@
|
|||
h1. Net::LDAP for Ruby
|
||||
# Net::LDAP for Ruby
|
||||
|
||||
Issues & Project Homepage
|
||||
|
||||
"http://rubyforge.org/projects/net-ldap":http://rubyforge.org/projects/net-ldap
|
||||
|
||||
Code
|
||||
|
||||
"git://github.com/RoryO/ruby-net-ldap.git":git://github.com/RoryO/ruby-net-ldap.git
|
||||
|
||||
h2. DESCRIPTION
|
||||
## DESCRIPTION
|
||||
|
||||
Pure Ruby LDAP library.
|
||||
|
||||
h2. FEATURES/PROBLEMS
|
||||
## Where
|
||||
|
||||
### Issues & Project Homepage
|
||||
|
||||
[http://rubyforge.org/projects/net-ldap][http://rubyforge.org/projects/net-ldap]
|
||||
|
||||
### Code
|
||||
|
||||
[git://github.com/RoryO/ruby-net-ldap.git][git://github.com/RoryO/ruby-net-ldap.git]
|
||||
|
||||
## FEATURES/PROBLEMS
|
||||
|
||||
The Lightweight Directory Access Protocol (LDAP) is an Internet protocol for
|
||||
accessing distributed directory services.
|
||||
|
@ -23,15 +25,15 @@ LDAP client features and a subset of server features as well.
|
|||
* Standards-based (going for RFC 4511)
|
||||
* Portable: 100% Ruby
|
||||
|
||||
h2. SYNOPSIS
|
||||
## SYNOPSIS
|
||||
|
||||
See Net::LDAP for documentation and usage samples.
|
||||
|
||||
h2. REQUIREMENTS
|
||||
## REQUIREMENTS
|
||||
|
||||
Net::LDAP requires Ruby 1.8.7-compliant interpreter or better.
|
||||
|
||||
h2. INSTALL
|
||||
## INSTALL
|
||||
|
||||
Net::LDAP is a pure Ruby library. It does not require any external libraries.
|
||||
You can install the RubyGems version of Net::LDAP available from the usual
|
||||
|
@ -42,7 +44,7 @@ sources.
|
|||
There is no installation required if using a source release. Simply
|
||||
unarchive and require 'lib/net'.
|
||||
|
||||
h2. CREDITS
|
||||
## CREDITS
|
||||
|
||||
Net::LDAP was originally developed by:
|
||||
|
||||
|
@ -50,12 +52,12 @@ Net::LDAP was originally developed by:
|
|||
|
||||
Contributions since:
|
||||
|
||||
* Austin Ziegler <halostatue@gmail.com>
|
||||
* Emiel van de Laar <gemiel@gmail.com>
|
||||
* Rory O'Connell <rory.ocon@gmail.com>
|
||||
* Kaspar Schiess <kaspar.schiess@absurd.li>
|
||||
* Austin Ziegler <austin@rubyforge.com>
|
||||
|
||||
h2. LICENSE
|
||||
## LICENSE
|
||||
|
||||
Copyright (C) 2006 by Francis Cianfrocca
|
||||
|
160
Rakefile
160
Rakefile
|
@ -1,67 +1,125 @@
|
|||
require "rubygems"
|
||||
require 'hanna/rdoctask'
|
||||
require 'hoe'
|
||||
|
||||
$LOAD_PATH.unshift('lib')
|
||||
|
||||
require 'net/ldap'
|
||||
|
||||
require "rake/gempackagetask"
|
||||
require "rake/rdoctask"
|
||||
|
||||
require "rake/testtask"
|
||||
Rake::TestTask.new do |t|
|
||||
t.libs << "test"
|
||||
t.test_files = FileList["test/test_*.rb"]
|
||||
t.verbose = true
|
||||
PKG_NAME = 'net-ldap'
|
||||
PKG_VERSION = Net::LDAP::VERSION
|
||||
PKG_DIST = "#{PKG_NAME}-#{PKG_VERSION}"
|
||||
PKG_TAR = "pkg/#{PKG_DIST}.tar.gz"
|
||||
MANIFEST = File.read("Manifest.txt").split
|
||||
|
||||
Hoe.spec PKG_NAME do
|
||||
self.readme_file = "README.markdown"
|
||||
self.version = PKG_VERSION
|
||||
self.rubyforge_name = PKG_NAME
|
||||
|
||||
developer "Francis Cianfrocca", "blackhedd@rubyforge.org"
|
||||
developer "Emiel van de Laar", "gemiel@gmail.com"
|
||||
developer "Rory O'Connell", "rory.ocon@gmail.com"
|
||||
developer "Kaspar Schiess", "kaspar.schiess@absurd.li"
|
||||
developer "Austin Ziegler", "austin@rubyforge.org"
|
||||
|
||||
self.url = %W(http://net-ldap.rubyforge.org/ http://github.com/RoryO/ruby-net-ldap)
|
||||
|
||||
self.summary = "Pure Ruby LDAP support library with most client features and some server features."
|
||||
self.changes = paragraphs_of(self.history_file, 0..1).join("\n\n")
|
||||
self.description = paragraphs_of(self.readme_file, 2..2).join("\n\n")
|
||||
|
||||
extra_dev_deps << [ "archive-tar-minitar", "~>0.5.1" ]
|
||||
extra_dev_deps << [ "hanna", "~>0.1.2" ]
|
||||
clean_globs << "coverage"
|
||||
|
||||
# This is a lie because I will continue to use Archive::Tar::Minitar.
|
||||
self.need_tar = false
|
||||
end
|
||||
|
||||
require 'spec/rake/spectask'
|
||||
Spec::Rake::SpecTask.new
|
||||
desc "Build a Net-LDAP .tar.gz distribution."
|
||||
task :tar => [ PKG_TAR ]
|
||||
file PKG_TAR => [ :test ] do |t|
|
||||
require 'archive/tar/minitar'
|
||||
require 'zlib'
|
||||
files = MANIFEST.map { |f|
|
||||
fn = File.join(PKG_DIST, f)
|
||||
tm = File.stat(f).mtime
|
||||
|
||||
task :default => ["test", 'spec']
|
||||
if File.directory?(f)
|
||||
{ :name => fn, :mode => 0755, :dir => true, :mtime => tm }
|
||||
else
|
||||
mode = if f =~ %r{^bin}
|
||||
0755
|
||||
else
|
||||
0644
|
||||
end
|
||||
data = File.read(f)
|
||||
{ :name => fn, :mode => mode, :data => data, :size => data.size,
|
||||
:mtime => tm }
|
||||
end
|
||||
}
|
||||
|
||||
# This builds the actual gem. For details of what all these options
|
||||
# mean, and other ones you can add, check the documentation here:
|
||||
#
|
||||
# http://rubygems.org/read/chapter/20
|
||||
#
|
||||
spec = Gem::Specification.new do |s|
|
||||
begin
|
||||
unless File.directory?(File.dirname(t.name))
|
||||
require 'fileutils'
|
||||
File.mkdir_p File.dirname(t.name)
|
||||
end
|
||||
tf = File.open(t.name, 'wb')
|
||||
gz = Zlib::GzipWriter.new(tf)
|
||||
tw = Archive::Tar::Minitar::Writer.new(gz)
|
||||
|
||||
# Change these as appropriate
|
||||
s.name = "net-ldap"
|
||||
s.version = "0.1.0"
|
||||
s.summary = "Net::LDAP is an LDAP support library written in pure Ruby. It supports most LDAP client features and a subset of server features as well."
|
||||
s.authors = [
|
||||
"Francis Cianfrocca",
|
||||
"Austin Ziegler",
|
||||
"Emiel van de Laar",
|
||||
"Rory O\'Connell",
|
||||
"Kaspar Schiess"]
|
||||
files.each do |entry|
|
||||
if entry[:dir]
|
||||
tw.mkdir(entry[:name], entry)
|
||||
else
|
||||
tw.add_file_simple(entry[:name], entry) { |os|
|
||||
os.write(entry[:data])
|
||||
}
|
||||
end
|
||||
end
|
||||
ensure
|
||||
tw.close if tw
|
||||
gz.close if gz
|
||||
end
|
||||
end
|
||||
task :package => [ PKG_TAR ]
|
||||
|
||||
s.description = "Pure Ruby LDAP library"
|
||||
desc "Build the manifest file from the current set of files."
|
||||
task :build_manifest do |t|
|
||||
require 'find'
|
||||
|
||||
# Add any extra files to include in the gem
|
||||
s.files = %w(COPYING History.txt LICENSE Rakefile README.txt) + Dir.glob("{spec,test,lib/**/*}")
|
||||
s.require_paths = ["lib"]
|
||||
paths = []
|
||||
Find.find(".") do |path|
|
||||
next if File.directory?(path)
|
||||
next if path =~ /\.svn/
|
||||
next if path =~ /\.git/
|
||||
next if path =~ /\.hoerc/
|
||||
next if path =~ /\.swp$/
|
||||
next if path =~ %r{coverage/}
|
||||
next if path =~ /~$/
|
||||
paths << path.sub(%r{^\./}, '')
|
||||
end
|
||||
|
||||
File.open("Manifest.txt", "w") do |f|
|
||||
f.puts paths.sort.join("\n")
|
||||
end
|
||||
|
||||
puts paths.sort.join("\n")
|
||||
end
|
||||
|
||||
# This task actually builds the gem. We also regenerate a static
|
||||
# .gemspec file, which is useful if something (i.e. GitHub) will
|
||||
# be automatically building a gem for this project. If you're not
|
||||
# using GitHub, edit as appropriate.
|
||||
#
|
||||
# To publish your gem online, install the 'gemcutter' gem; Read more
|
||||
# about that here: http://gemcutter.org/pages/gem_docs
|
||||
Rake::GemPackageTask.new(spec) do |pkg|
|
||||
pkg.gem_spec = spec
|
||||
# require "rake/testtask"
|
||||
# Rake::TestTask.new do |t|
|
||||
# t.libs << "test"
|
||||
# t.test_files = FileList["test/test_*.rb"]
|
||||
# t.verbose = true
|
||||
# end
|
||||
|
||||
# Generate the gemspec file for github.
|
||||
file = File.dirname(__FILE__) + "/#{spec.name}.gemspec"
|
||||
File.open(file, "w") {|f| f << spec.to_ruby }
|
||||
end
|
||||
# require 'spec/rake/spectask'
|
||||
# Spec::Rake::SpecTask.new
|
||||
|
||||
# Generate documentation
|
||||
Rake::RDocTask.new do |rd|
|
||||
rd.main = "README.txt"
|
||||
rd.rdoc_files.include("README.txt", "lib/**/*.rb")
|
||||
rd.rdoc_dir = "rdoc"
|
||||
end
|
||||
# task :default => ["test", 'spec']
|
||||
|
||||
desc 'Clear out RDoc and generated packages'
|
||||
task :clean => [:clobber_rdoc, :clobber_package] do
|
||||
rm "#{spec.name}.gemspec"
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue