From null at cozmixng.org Wed Jul 6 10:07:52 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Wed, 06 Jul 2011 14:07:52 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] remove needless gem dependencies. Message-ID: <20110706140924.7B7602C4156@taiyaki.ru> Kouhei Sutou 2011-07-06 14:07:52 +0000 (Wed, 06 Jul 2011) New Revision: ae2055b8d9190d1f0ffd97a4bdc622b793418da0 Log: remove needless gem dependencies. Modified files: Rakefile Modified: Rakefile (+0 -3) =================================================================== --- Rakefile 2011-06-14 13:48:07 +0000 (916b7a0) +++ Rakefile 2011-07-06 14:07:52 +0000 (05dfd18) @@ -43,9 +43,6 @@ Jeweler::Tasks.new do |_spec| "TODO", "*.txt"] spec.test_files = FileList['test/test_*.rb'] - Bundler.load.dependencies_for(:default).each do |dependency| - spec.add_runtime_dependency(dependency.name, dependency.requirement) - end spec.description = <<-EOF 'ActiveLdap' is a ruby extension library which provides a clean objected oriented interface to the Ruby/LDAP library. It was inspired From null at cozmixng.org Wed Jul 6 10:10:13 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Wed, 06 Jul 2011 14:10:13 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] remove needless version checks. Message-ID: <20110706141145.282D42C4151@taiyaki.ru> Kouhei Sutou 2011-07-06 14:10:13 +0000 (Wed, 06 Jul 2011) New Revision: bcca2fcd48fdbc0cffc64d699cbe1787b4de85a8 Log: remove needless version checks. They should be done by Bundler. Modified files: lib/active_ldap.rb Modified: lib/active_ldap.rb (+4 -17) =================================================================== --- lib/active_ldap.rb 2011-07-06 14:07:52 +0000 (4e9dffa) +++ lib/active_ldap.rb 2011-07-06 14:10:13 +0000 (391262c) @@ -887,21 +887,8 @@ # package, and I'd like to see it prove helpful to more people than just myself. # -require_gem_if_need = Proc.new do |library_name, gem_name, *gem_args| - gem_name ||= library_name - begin - if !gem_args.empty? and Object.const_defined?(:Gem) - gem gem_name, *gem_args - end - require library_name - rescue LoadError - require 'rubygems' - gem gem_name, *gem_args - require library_name - end -end - -require_gem_if_need.call("active_model", "activemodel", "~> 3.1.0.rc2") +require "rubygems" +require "active_model" require "active_support/core_ext" module ActiveLdap @@ -916,8 +903,8 @@ else end begin - require_gem_if_need.call("locale", nil, "= 2.0.5") - require_gem_if_need.call("fast_gettext", nil, "= 0.5.8") + require "locale" + require "fast_gettext" rescue LoadError end require 'active_ldap/get_text' From null at cozmixng.org Wed Jul 6 10:11:18 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Wed, 06 Jul 2011 14:11:18 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] remove needless requires. Message-ID: <20110706141250.3C2522C4151@taiyaki.ru> Kouhei Sutou 2011-07-06 14:11:18 +0000 (Wed, 06 Jul 2011) New Revision: d51a3417ff1256ee6681cfafc88b36333152ac5d Log: remove needless requires. They should be done by 'bundle exec'. Modified files: test/run-test.rb Modified: test/run-test.rb (+0 -4) =================================================================== --- test/run-test.rb 2011-07-06 14:10:13 +0000 (eff6b87) +++ test/run-test.rb 2011-07-06 14:11:18 +0000 (60aa155) @@ -4,10 +4,6 @@ $VERBOSE = true $KCODE = 'u' if RUBY_VERSION < "1.9" -require 'yaml' - -require 'bundler/setup' - base_dir = File.expand_path(File.dirname(__FILE__)) top_dir = File.expand_path(File.join(base_dir, "..")) $LOAD_PATH.unshift(File.join(top_dir)) From null at cozmixng.org Wed Jul 6 10:25:31 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Wed, 06 Jul 2011 14:25:31 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] remove needless rails_generators. Message-ID: <20110706142702.C387A2C4156@taiyaki.ru> Kouhei Sutou 2011-07-06 14:25:31 +0000 (Wed, 06 Jul 2011) New Revision: 284ab18d617717822777138a4619985875c6555c Log: remove needless rails_generators. Removed files: rails_generators/model_active_ldap/USAGE rails_generators/model_active_ldap/model_active_ldap_generator.rb rails_generators/model_active_ldap/templates/model_active_ldap.rb rails_generators/model_active_ldap/templates/unit_test.rb rails_generators/scaffold_active_ldap/scaffold_active_ldap_generator.rb rails_generators/scaffold_active_ldap/templates/ldap.yml Modified files: Rakefile Modified: Rakefile (+1 -1) =================================================================== --- Rakefile 2011-07-06 14:11:18 +0000 (05dfd18) +++ Rakefile 2011-07-06 14:25:31 +0000 (0325845) @@ -32,7 +32,7 @@ Jeweler::Tasks.new do |_spec| spec.email = ['redpig at dataspill.org', 'kou at cozmixng.org'] spec.summary = 'ActiveLdap is a object-oriented API to LDAP' spec.homepage = 'http://ruby-activeldap.rubyforge.org/' - spec.files = FileList["{lib,rails,rails_generators}/**/*", + spec.files = FileList["lib/**/*", "{benchmark,examples,po}/**", "bin/*", "CHANGES", Deleted: rails_generators/model_active_ldap/USAGE (+0 -17) 100644 =================================================================== --- rails_generators/model_active_ldap/USAGE 2011-07-06 14:11:18 +0000 (8c2d72c) +++ /dev/null @@ -1,17 +0,0 @@ -Description: - The model_active_ldap generator creates stubs for a new model. - - The generator takes a model name as its argument. The model name may be given in CamelCase or under_score and - should not be suffixed with 'Model'. - - The generator creates a model class in app/models, a test suite in test/unit, and test fixtures in - test/fixtures/singular_name.yml. It will not create a migration. - -Examples: - ./script/generate model_active_ldap user - - This will create a User model: - Model: app/models/user.rb - Test: test/unit/user_test.rb - Fixtures: test/fixtures/users.yml - Deleted: rails_generators/model_active_ldap/model_active_ldap_generator.rb (+0 -69) 100644 =================================================================== --- rails_generators/model_active_ldap/model_active_ldap_generator.rb 2011-07-06 14:11:18 +0000 (003bb47) +++ /dev/null @@ -1,69 +0,0 @@ -require 'active_ldap' - -class ModelActiveLdapGenerator < Rails::Generator::NamedBase - include ActiveLdap::GetTextSupport - - default_options :dn_attribute => "cn", :classes => nil - - def manifest - record do |m| - # Check for class naming collisions. - m.class_collisions class_path, class_name, "#{class_name}Test" - - # Model and test directories. - m.directory File.join('app/models', class_path) - m.directory File.join('test/unit', class_path) - - # Model class and unit test. - m.template('model_active_ldap.rb', - File.join('app/models', class_path, "#{file_name}.rb"), - :assigns => {:ldap_mapping => ldap_mapping}) - m.template('unit_test.rb', - File.join('test/unit', class_path, "#{file_name}_test.rb")) - end - end - - private - def add_options!(opt) - opt.separator '' - opt.separator 'Options:' - opt.on("--dn-attribute=ATTRIBUTE", - _("Use ATTRIBUTE as default DN attribute for " \ - "instances of this model"), - _("(default: %s)") % default_options[:dn_attribute]) do |attribute| - options[:dn_attribute] = attribute - end - - opt.on("--prefix=PREFIX", - _("Use PREFIX as prefix for this model"), - _("(default: %s)") % "ou=Names") do |prefix| - options[:prefix] = prefix - end - - opt.on("--classes=CLASS,CLASS,...", - Array, - "Use CLASSES as required objectClass for instances of this model", - "(default: %s)" % default_options[:classes]) do |classes| - options[:classes] = classes - end - end - - def prefix - options[:prefix] || default_prefix - end - - def default_prefix - "ou=#{name.demodulize.pluralize}" - end - - def ldap_mapping(indent=' ') - mapping = "ldap_mapping " - mapping_options = [":dn_attribute => #{options[:dn_attribute].dump}"] - mapping_options << ":prefix => #{prefix.dump}" - if options[:classes] - mapping_options << ":classes => #{options[:classes].inspect}" - end - mapping_options = mapping_options.join(",\n#{indent}#{' ' * mapping.size}") - "#{indent}#{mapping}#{mapping_options}" - end -end Deleted: rails_generators/model_active_ldap/templates/model_active_ldap.rb (+0 -3) 100644 =================================================================== --- rails_generators/model_active_ldap/templates/model_active_ldap.rb 2011-07-06 14:11:18 +0000 (cdfa66b) +++ /dev/null @@ -1,3 +0,0 @@ -class <%= class_name %> < ActiveLdap::Base -<%= ldap_mapping %> -end Deleted: rails_generators/model_active_ldap/templates/unit_test.rb (+0 -8) 100644 =================================================================== --- rails_generators/model_active_ldap/templates/unit_test.rb 2011-07-06 14:11:18 +0000 (42498db) +++ /dev/null @@ -1,8 +0,0 @@ -require 'test_helper' - -class <%= class_name %>Test < Test::Unit::TestCase - # Replace this with your real tests. - def test_truth - assert true - end -end Deleted: rails_generators/scaffold_active_ldap/scaffold_active_ldap_generator.rb (+0 -7) 100644 =================================================================== --- rails_generators/scaffold_active_ldap/scaffold_active_ldap_generator.rb 2011-07-06 14:11:18 +0000 (35ad937) +++ /dev/null @@ -1,7 +0,0 @@ -class ScaffoldActiveLdapGenerator < Rails::Generator::Base - def manifest - record do |m| - m.template("ldap.yml", File.join("config", "ldap.yml")) - end - end -end Deleted: rails_generators/scaffold_active_ldap/templates/ldap.yml (+0 -18) 100644 =================================================================== --- rails_generators/scaffold_active_ldap/templates/ldap.yml 2011-07-06 14:11:18 +0000 (c724f46) +++ /dev/null @@ -1,18 +0,0 @@ -development: - host: 127.0.0.1 - base: dc=devel,dc=local,dc=net - bind_dn: cn=admin,dc=local,dc=net - password: secret - -test: - host: 127.0.0.1 - base: dc=test,dc=local,dc=net - bind_dn: cn=admin,dc=local,dc=net - password: secret - -production: - host: 127.0.0.1 - method: :tls - base: dc=production,dc=local,dc=net - bind_dn: cn=admin,dc=local,dc=net - password: secret From null at cozmixng.org Wed Jul 6 10:26:07 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Wed, 06 Jul 2011 14:26:07 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] 3.0.0 -> 3.1.0. Message-ID: <20110706142738.AF8852C4156@taiyaki.ru> Kouhei Sutou 2011-07-06 14:26:07 +0000 (Wed, 06 Jul 2011) New Revision: ac2e93c72fa78ec1527fffef0649c52fc07ca3f2 Log: 3.0.0 -> 3.1.0. Modified files: lib/active_ldap.rb Modified: lib/active_ldap.rb (+1 -1) =================================================================== --- lib/active_ldap.rb 2011-07-06 14:25:31 +0000 (391262c) +++ lib/active_ldap.rb 2011-07-06 14:26:07 +0000 (dff9029) @@ -892,7 +892,7 @@ require "active_model" require "active_support/core_ext" module ActiveLdap - VERSION = "3.0.0" + VERSION = "3.1.0" autoload :Command, "active_ldap/command" end From null at cozmixng.org Wed Jul 6 10:27:02 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Wed, 06 Jul 2011 14:27:02 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] use the latest Rails. Message-ID: <20110706142831.BB28E2C4156@taiyaki.ru> Kouhei Sutou 2011-07-06 14:27:02 +0000 (Wed, 06 Jul 2011) New Revision: 7cda171ca08596f1e3b9bd1286d393ae27174cda Log: use the latest Rails. Modified files: Gemfile Modified: Gemfile (+1 -1) =================================================================== --- Gemfile 2011-07-06 14:26:07 +0000 (90694d9) +++ Gemfile 2011-07-06 14:27:02 +0000 (09a7a74) @@ -2,7 +2,7 @@ source "http://rubygems.org" -gem 'activemodel', '~> 3.1.0.rc2' +gem 'activemodel', '~> 3.1.0.rc4' gem 'locale' gem 'fast_gettext' gem 'gettext_i18n_rails' From null at cozmixng.org Wed Jul 6 10:33:20 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Wed, 06 Jul 2011 14:33:20 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] add missing "*". Message-ID: <20110706143449.6C7CB2C4151@taiyaki.ru> Kouhei Sutou 2011-07-06 14:33:20 +0000 (Wed, 06 Jul 2011) New Revision: 5b14745a9ab375480b68146033dcad50965c55a0 Log: add missing "*". Modified files: Rakefile Modified: Rakefile (+1 -1) =================================================================== --- Rakefile 2011-07-06 14:27:02 +0000 (0325845) +++ Rakefile 2011-07-06 14:33:20 +0000 (68d9dad) @@ -33,7 +33,7 @@ Jeweler::Tasks.new do |_spec| spec.summary = 'ActiveLdap is a object-oriented API to LDAP' spec.homepage = 'http://ruby-activeldap.rubyforge.org/' spec.files = FileList["lib/**/*", - "{benchmark,examples,po}/**", + "{benchmark,examples,po}/**/*", "bin/*", "CHANGES", "COPYING", From null at cozmixng.org Thu Jul 7 19:49:22 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Thu, 07 Jul 2011 23:49:22 -0000 Subject: [activeldap-commit] activeldap/activeldap [master] [test] omit a test that takes a long time. Message-ID: <20110707235043.D3C842C4155@taiyaki.ru> Kouhei Sutou 2011-06-03 00:20:13 +0000 (Fri, 03 Jun 2011) New Revision: deeba29fcb9d3882a1fd900fad5630e47bdd8d98 Log: [test] omit a test that takes a long time. Modified files: test/test_connection.rb Modified: test/test_connection.rb (+1 -1) =================================================================== --- test/test_connection.rb 2011-07-06 14:33:20 +0000 (7d8cf29) +++ test/test_connection.rb 2011-06-03 00:20:13 +0000 (9a08b0d) @@ -71,10 +71,10 @@ class TestConnection < Test::Unit::TestCase priority :low def test_retry_limit_0_with_nonexistent_host + omit("this test will take a long time...") config = current_configuration.merge("host" => "192.168.29.29", "retry_limit" => 0) ActiveLdap::Base.setup_connection(config) - notify("maybe take a long time") assert_raise(ActiveLdap::ConnectionError) do ActiveLdap::Base.find(:first) end From null at cozmixng.org Thu Jul 7 20:02:26 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Fri, 08 Jul 2011 00:02:26 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] use clean task. Message-ID: <20110708001055.ABE342C42FD@taiyaki.ru> Kouhei Sutou 2011-07-08 00:02:26 +0000 (Fri, 08 Jul 2011) New Revision: 4ecf27ff482d64226d1259774ca1c6afe060aa4d Log: use clean task. Modified files: Rakefile Modified: Rakefile (+2 -1) =================================================================== --- Rakefile 2011-07-08 00:01:43 +0000 (1c7ab65) +++ Rakefile 2011-07-08 00:02:26 +0000 (10bf745) @@ -8,7 +8,8 @@ require 'bundler/setup' require 'jeweler' require 'rake/testtask' -require 'yard' +require "rake/clean" +require "yard" if YAML.const_defined?(:ENGINE) begin From null at cozmixng.org Thu Jul 7 20:01:14 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Fri, 08 Jul 2011 00:01:14 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] [doc] use textile for README. Message-ID: <20110708001055.2F0FA2C42BE@taiyaki.ru> Kouhei Sutou 2011-07-08 00:01:14 +0000 (Fri, 08 Jul 2011) New Revision: 1e49f58dba191a9fb4cdc205d1c707f0cb2acf00 Log: [doc] use textile for README. Modified files: Rakefile Renamed files: README.textile (from README) Renamed: README.textile (+8 -8) 98% =================================================================== --- README 2011-07-08 00:00:10 +0000 (1180f51) +++ README.textile 2011-07-08 00:01:14 +0000 (c85b4f9) @@ -1,4 +1,4 @@ -= ActiveLdap +h1. ActiveLdap ruby library for object-oriented LDAP interction @@ -11,7 +11,7 @@ Contributors:: * Patrick Cole * Google Inc. -== DESCRIPTION +h2. DESCRIPTION 'ActiveLdap' is a ruby extension library which provides a clean objected oriented interface to the Ruby/LDAP[0] library. It was inspired by @@ -24,7 +24,7 @@ It is also available on the web at: http://ruby-activeldap.rubyforge.org/ -== PREREQUISITES +h2. PREREQUISITES [Ruby intepreter] One of them: @@ -39,11 +39,11 @@ http://ruby-activeldap.rubyforge.org/ * ActiveRecord[http://activerecord.rubyonrails.org] -== NOTES +h2. NOTES * Only GSSAPI SASL support exists due to Ruby/LDAP limitations -== RAILS +h2. RAILS There is a small rails plugin included that allows the use of a file named 'config/ldap.yml' in the config directory of @@ -81,7 +81,7 @@ When your application starts up, the plugin will call ActiveLdap::Base.setup_connection using the parameters specified for your current environment. -== Model +h2. Model Here is some examples. @@ -109,7 +109,7 @@ app/model/ou.rb: :classes => ["top", "organizationalUnit"] end -== LICENCE +h2. LICENCE This program is free software; you can redistribute it and/or modify it. It is dual licensed under Ruby's license and under the terms of the GNU General @@ -118,7 +118,7 @@ or (at your option) any later version. Please see the file LICENSE for the terms of the licence. -== THANKS +h2. THANKS This list may not be correct. If you notice mistakes of this list, please point out. Modified: Rakefile (+2 -3) =================================================================== --- Rakefile 2011-07-08 00:00:10 +0000 (1fb33b8) +++ Rakefile 2011-07-08 00:01:14 +0000 (81c712a) @@ -40,9 +40,8 @@ Jeweler::Tasks.new do |_spec| "COPYING", "Gemfile", "LICENSE", - "README", - "TODO", - "*.txt"] + "README.textile", + "TODO"] spec.test_files = FileList['test/test_*.rb'] spec.description = <<-EOF 'ActiveLdap' is a ruby extension library which provides a clean From null at cozmixng.org Thu Jul 7 20:17:48 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Fri, 08 Jul 2011 00:17:48 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] [doc] fix markup in news. Message-ID: <20110708001946.570E82C415D@taiyaki.ru> Kouhei Sutou 2011-07-08 00:17:48 +0000 (Fri, 08 Jul 2011) New Revision: ab1eb3fa4241938943e54a2ba185b7313c709143 Log: [doc] fix markup in news. Modified files: doc/text/news.textile Modified: doc/text/news.textile (+172 -167) =================================================================== --- doc/text/news.textile 2011-07-08 00:08:46 +0000 (a77e8ae) +++ doc/text/news.textile 2011-07-08 00:17:48 +0000 (b5f791d) @@ -77,54 +77,54 @@ h2. 1.1.0: 2009-07-18 * Improved tutorial. [Kazuaki Takase] * Improvements: - * API: - * [#26] Supported to_xml for associations. [achemze] - * ActiveLdap::Base.delete_all(filter=nil, options={}) -> - ActiveLdap::Base.delete_all(filter_or_options={}). - Sure, old method signature is also still supported. - * belongs_to(:many) with :foreign_key is deprecated. - Use :primary_key instead of :foreign_key. [Kazuaki Takase] - * Means of has_many's :primary_key and :foreign_key are inverted. - [Kazuaki Takase] - * [experimental] Added ldap_field ActionView helper to - generate form fileds for a LDAP entry. - * Suppressed needless attributes updating. +** API: +*** [#26] Supported to_xml for associations. [achemze] +*** ActiveLdap::Base.delete_all(filter=nil, options={}) -> + ActiveLdap::Base.delete_all(filter_or_options={}). + Sure, old method signature is also still supported. +*** belongs_to(:many) with :foreign_key is deprecated. + Use :primary_key instead of :foreign_key. [Kazuaki Takase] +*** Means of has_many's :primary_key and :foreign_key are inverted. + [Kazuaki Takase] +*** [experimental] Added ldap_field ActionView helper to + generate form fileds for a LDAP entry. +** Suppressed needless attributes updating. * Dependencies: - * Re-supported GetText. - * ActiveRecord 2.3.2 is only supported. +** Re-supported GetText. +** ActiveRecord 2.3.2 is only supported. h2. 1.0.9 * Added documents in Japanese. [Kazuaki Takase] * Supported Ruby 1.9.1. - * [#20] [Ruby 1.9 Support] :: Running Tests [Alexey.Chebotar] +** [#20] [Ruby 1.9 Support] :: Running Tests [Alexey.Chebotar] * Supported Rails 2.3.2. - * [#18] [Rails 2.3 Support] :: Running WEBrick Hangs [Alexey.Chebotar] +** [#18] [Rails 2.3 Support] :: Running WEBrick Hangs [Alexey.Chebotar] * Bug fixes: - * Fixed blank values detection. [David Morton] - * [#22] Ruby 1.8.6 p287 :: Undefined methods [Alexey.Chebotar] - * Fixed gem loading. [Tiago Fernandes] - * Fixed DN change via #base=. [David Morton] - * Fixed infinite retry on timeout. - * Fixed needless reconnection. +** Fixed blank values detection. [David Morton] +** [#22] Ruby 1.8.6 p287 :: Undefined methods [Alexey.Chebotar] +** Fixed gem loading. [Tiago Fernandes] +** Fixed DN change via #base=. [David Morton] +** Fixed infinite retry on timeout. +** Fixed needless reconnection. * API improvements: - * Removed needless instance methods: #prefix=, - #dn_attribute=, #sort_by=, #order=, #required_classes=, - #recommended_classes= and #excluded_classes. [David Morton] - * Removed obsolete scafoold_al generator. - * Reduced default :retry_limit. - * Supported association as parameter. [Joe Francis] - * Normalized schema attribute name. [Tim Hermans] - * Suppressed AuthenticationError -> ConnectionError - conversion on reconnection. [Kazuaki Takase] - * Added ActiveLdap::Schema#dump. - * ActiveLdap::Base.establish_connection -> - ActiveLdap::Base.setup_connection. - * Supported ActiveLdap::Base.find(:last). - * Added convenient methods: - * ActiveLdap::Base.first - * ActiveLdap::Base.last - * ActiveLdap::Base.all +** Removed needless instance methods: #prefix=, + #dn_attribute=, #sort_by=, #order=, #required_classes=, + #recommended_classes= and #excluded_classes. [David Morton] +** Removed obsolete scafoold_al generator. +** Reduced default :retry_limit. +** Supported association as parameter. [Joe Francis] +** Normalized schema attribute name. [Tim Hermans] +** Suppressed AuthenticationError -> ConnectionError + conversion on reconnection. [Kazuaki Takase] +** Added ActiveLdap::Schema#dump. +** ActiveLdap::Base.establish_connection -> + ActiveLdap::Base.setup_connection. +** Supported ActiveLdap::Base.find(:last). +** Added convenient methods: +*** ActiveLdap::Base.first +*** ActiveLdap::Base.last +*** ActiveLdap::Base.all h2. 1.0.2 @@ -142,24 +142,24 @@ h2. 1.0.2 * Accepted :class_name for belong_to and has_many option. * Improved default port guess. * Bug fixes: - * [#4] ModifyRecord#load doesn't operate atomic. [gwarf12] - * [#5] to_xml supports :except option. [baptiste.grenier] - * [#6] to_xml uses ActiveResource format. [baptiste.grenier] - * Out of ranged GeneralizedTime uses Time.at(0) as fallback value. - [Richard Nicholas] - * ActiveLdap::Base#to_s uses #to_ldif. [Kazuhiro NISHIYAMA] - * Fixed excess prefix extraction. [Grzegorz Marsza?ek] - * Skiped read only attribute validation. [???????] - * Treated "" as empty value. [Ted Lepich] - * [#9][#16] Reduced raising when DN value is invalid. - [danger1986][Alexey.Chebotar] - * [#10][#12] Fixed needless ',' is appeared. [michael.j.konopka] - * [#11] Required missing 'active_ldap/user_password'. [michael.j.konopka] - * [#13] Returned entries if has_many :wrap has nonexistent entry. - [ingersoll] - * [#15] Fixed type error on computing DN. [ery.lee] - * ">=" filter operator doesn't work. [id:dicdak] - * [#17] ActiveLdap::Base.create doesn't raise exception. [Alexey.Chebotar] +** [#4] ModifyRecord#load doesn't operate atomic. [gwarf12] +** [#5] to_xml supports :except option. [baptiste.grenier] +** [#6] to_xml uses ActiveResource format. [baptiste.grenier] +** Out of ranged GeneralizedTime uses Time.at(0) as fallback value. + [Richard Nicholas] +** ActiveLdap::Base#to_s uses #to_ldif. [Kazuhiro NISHIYAMA] +** Fixed excess prefix extraction. [Grzegorz Marsza?ek] +** Skiped read only attribute validation. [???????] +** Treated "" as empty value. [Ted Lepich] +** [#9][#16] Reduced raising when DN value is invalid. + [danger1986][Alexey.Chebotar] +** [#10][#12] Fixed needless ',' is appeared. [michael.j.konopka] +** [#11] Required missing 'active_ldap/user_password'. [michael.j.konopka] +** [#13] Returned entries if has_many :wrap has nonexistent entry. + [ingersoll] +** [#15] Fixed type error on computing DN. [ery.lee] +** ">=" filter operator doesn't work. [id:dicdak] +** [#17] ActiveLdap::Base.create doesn't raise exception. [Alexey.Chebotar] h2. 1.0.1 @@ -183,35 +183,36 @@ h2. 0.10.0 * Implemented LDIF parser. * Improved validation: - * Added some validations. - * Fixed SINGLE-VALUE validation. [#17763] - (Reported by Naoto Morishima) +** Added some validations. +** Fixed SINGLE-VALUE validation. [#17763] + (Reported by Naoto Morishima) * Supported JNDI as backend. * Improved auto reconnection. * Supported Rails 2.0.2. * Improved performance. (4x) * [API CHANGE]: removed "'binary' =>" from getter result. - +
   e.g.:
     before:
         user.user_certificate # => {"binary" => "..."}
        now:
         user.user_certificate # => "..."
+  
* Added :excluded_classed ldap_mapping option. * Logged operation time used for LDAP operation. * Improved API: - * Accepted non String value for find(:value => XXX). - (Suggested by Marc Dequ?n) - * Accepted DN as ActiveLdap::Base.new(XXX). - (Reported by Jeremy Pruitt) - * Treated empty password for smiple bind as anonymous bind. - (Suggested by Bodaniel Jeans) - * Ensured adding "objectClass" for find's :attribute value. [#16946] - (Suggested by Nobody) - * Fixed a GeneralizedTime type casting bug. - (Reported by Bodaniel Jeanes) - * Supported :base and :prefix search/find option value escaping. - (Suggested by David Morton) +** Accepted non String value for find(:value => XXX). + (Suggested by Marc Dequ?n) +** Accepted DN as ActiveLdap::Base.new(XXX). + (Reported by Jeremy Pruitt) +** Treated empty password for smiple bind as anonymous bind. + (Suggested by Bodaniel Jeans) +** Ensured adding "objectClass" for find's :attribute value. [#16946] + (Suggested by Nobody) +** Fixed a GeneralizedTime type casting bug. + (Reported by Bodaniel Jeanes) +** Supported :base and :prefix search/find option value escaping. + (Suggested by David Morton) h2. 0.9.0 @@ -220,23 +221,23 @@ h2. 0.9.0 * Changed RubyGems name: ruby-activeldap -> activeldap. * Removed Log4r dependency. * Supported lazy connection establishing. - * [API CHANGE]: establish_connection doesn't connect LDAP server. +** [API CHANGE]: establish_connection doesn't connect LDAP server. * [API CHANGE]: Removed ActiveLdap::Base#establish_connection. * Added ActiveLdap::Base#bind. (use this instead of #establish_connection) * Supported implicit acts_as_tree. * [API CHANGE]: Supported type casting. * Supported :uri option in configuration. * Improved Rails integration: - * Followed Rails 2.0 changes. - * AL-Admin: - * Supported lang parameter in URL. - * Improved design a bit. (Please someone help us!) - * Supported schema inspection. - * Supported objectClass modifiation. - * Rails plugin: - * Added ActiveLdap::VERSION check. - * Added model_active_ldap generator. - * Renamed scaffold_al generator to scaffold_active_ldap. +** Followed Rails 2.0 changes. +** AL-Admin: +*** Supported lang parameter in URL. +*** Improved design a bit. (Please someone help us!) +*** Supported schema inspection. +*** Supported objectClass modifiation. +** Rails plugin: +*** Added ActiveLdap::VERSION check. +*** Added model_active_ldap generator. +*** Renamed scaffold_al generator to scaffold_active_ldap. h2. 0.8.3 @@ -250,31 +251,31 @@ h2. 0.8.3 h2. 0.8.2 * Added Net::LDAP support! - * supported SASL Digest-MD5 authentication with Net::LDAP. +** supported SASL Digest-MD5 authentication with Net::LDAP. * improved LDAP server support: - * improved Sun DS support. - * improved ActiveDirectory support. Thanks to Ernie Miller! - * improved Fedora-DS support. Thanks to Daniel Pfile! +** improved Sun DS support. +** improved ActiveDirectory support. Thanks to Ernie Miller! +** improved Fedora-DS support. Thanks to Daniel Pfile! * improved existing functions: - * improved DN handling. Thanks to James Hughes! - * improved SASL bind. - * improved old API check. - * improved schema handling. Thanks to Christoph Lipp! - * improved filter notification. +** improved DN handling. Thanks to James Hughes! +** improved SASL bind. +** improved old API check. +** improved schema handling. Thanks to Christoph Lipp! +** improved filter notification. * updated documents: - * updated Rails realted documenation. Thanks to James Hughes! - * updated documentation for the changes between 0.7.1 and 0.8.0. - Thanks to Buzz Chopra! +** updated Rails realted documenation. Thanks to James Hughes! +** updated documentation for the changes between 0.7.1 and 0.8.0. + Thanks to Buzz Chopra! * added new features: - * added scaffold_al generator for Rails. - * added required_classes to default filter value. Thanks to Jeff Hall! - * added :recommended_classes option to ldap_mapping. - * added :sort_by and :order options to find. - * added ActiveLdap::Base#to_param for ActionController. +** added scaffold_al generator for Rails. +** added required_classes to default filter value. Thanks to Jeff Hall! +** added :recommended_classes option to ldap_mapping. +** added :sort_by and :order options to find. +** added ActiveLdap::Base#to_param for ActionController. * fixed some bugs: - * fixed rake install/uninstall. - * fixed typos. Thanks to Nobody! - * fixed required_classes initialization. Thanks to James Hughes! +** fixed rake install/uninstall. +** fixed typos. Thanks to Nobody! +** fixed required_classes initialization. Thanks to James Hughes! h2. 0.8.1 @@ -325,13 +326,13 @@ h2. 0.8.0 * make save!() raise EntryNotSaved exception * to_xml() * clear_active_connections!() -- Conn per class - - make @@active_connections and name them by +** make @@active_connections and name them by * base_class() (just return the ancestor) * Separate ObjectClass changes to live in ActiveLDAP::ObjectClass - - add_objectclass - - remove_objectclass - - replace_objectclass - - disallow direct objectclass access? +** add_objectclass +** remove_objectclass +** replace_objectclass +** disallow direct objectclass access? * support ActiveRecord::Validations. * support ActiveRecord::Callbacks. * rename to ActiveLdap from ActiveLDAP to integrate RoR easily and enforce @@ -446,8 +447,8 @@ h2. 0.5.5 h2. 0.5.4 * Added Base#import to streamline the Base.find and Base.find_all methods - - Speeds up find and find_all by not accessing LDAP multiple times - for data we already have. +** Speeds up find and find_all by not accessing LDAP multiple times + for data we already have. * Added tests/benchmark which is a slightly modified version of excellent benchmarking code contributed by Ollivier Robert . @@ -455,7 +456,7 @@ h2. 0.5.4 h2. 0.5.3 * Changed attribute_method to send in associations - - fixes belongs_to (with local_kay) and inheritance around that +** fixes belongs_to (with local_kay) and inheritance around that h2. 0.5.2 @@ -463,19 +464,19 @@ h2. 0.5.2 h2. 0.5.1 -* Changed Schema2#class_attributes to return {:must => [], :may => []} +* Changed Schema2#class_attributes to return @{:must => [], :may => []}@ * Fixed Base#must and Base#may to return with full SUPerclass requirements h2. 0.5.0 * API CHANGE (as with all 0.x.0 changes) (towards ActiveRecord duck typing) - - Base#ldapattribute now always returns an array - - Base#ldapattribute(true) now returns a dup of an array, string, etc - when appropriate (old default) - This is just for convenience - - Base#ldapattribute returns the stored value, not just a .dup - - Associations methods return objects by default instead of just names. - Group.new('foo').members(false) will return names only. - - Base.connect returns true as one might expect +** Base#ldapattribute now always returns an array +** Base#ldapattribute(true) now returns a dup of an array, string, etc + when appropriate (old default) - This is just for convenience +** Base#ldapattribute returns the stored value, not just a .dup +** Associations methods return objects by default instead of just names. + Group.new('foo').members(false) will return names only. +** Base.connect returns true as one might expect * Value validation and changing (binary, etc) occur prior to write, and not immediately on attribute_method=(value). * Attribute method validity is now determined /on-the-fly/. @@ -498,58 +499,62 @@ h2. 0.5.0 h2. 0.4.4 * Fixed binary subtype forcing: - - was setting data as subtype ;binary even when not required +** was setting data as subtype ;binary even when not required * Added first set of unit tests. - - These will be cleaned up in later releases as more tests are added. +** These will be cleaned up in later releases as more tests are added. * Fixed subtype clobber non-subtype (unittest!) - - cn and cn;lang-blah: the last loaded won +** cn and cn;lang-blah: the last loaded won * Fixed multivalued subtypes from being shoved into a string (unittest!) - - an error with attribute_input_value +** an error with attribute_input_value h2. 0.4.3 * Fixed write (add) bugs introduced with last change - - only bug fixes until unittests are in place +** only bug fixes until unittests are in place h2. 0.4.2 * Added ruby-activeldap.gemspec * Integrated building a gem of 'ruby-activeldap' into Makefile.package * Added attr parsing cache to speed up repetitive calls: approx 13x speedup - - 100 usermod-binary-add calls - - Without attr parsing cache: - real 13m53.129s - user 13m11.350s - sys 0m7.030s - With attr parsing cache: - real 1m0.416s - user 0m28.390s - sys 0m2.380s +** 100 usermod-binary-add calls + +
+   Without attr parsing cache:
+     real    13m53.129s
+     user    13m11.350s
+     sys     0m7.030s
+   With attr parsing cache:
+     real    1m0.416s
+     user    0m28.390s
+     sys     0m2.380s
+   
h2. 0.4.1: * Schema2 was not correctly parsing objectClass entries. - - This is fixed for now but must be revisited. +** This is fixed for now but must be revisited. h2. 0.4.0 * Added #(arrays) argument which when true always returns arrays. e.g. - irb> user.cn(true) - => ['My Common Name'] +
+  irb> user.cn(true)
+  => ['My Common Name']
+  
This makes things easier for larger programming tasks. * Added subtype support: - - Uses Hash objects to specify the subtype - e.g. user.userCertificate = {'binary' => File.read('mycert.der')} - - Added recursive type enforcement along with the subtype handling - - This required overhauling the #write method. - - Please report any problems ASAP! :^) +** Uses Hash objects to specify the subtype + e.g. @user.userCertificate = {'binary' => File.read('mycert.der')}@ +** Added recursive type enforcement along with the subtype handling +** This required overhauling the #write method. +*** Please report any problems ASAP! :^) * Added automagic binary support - - subtype wrapping done automatically - - relies on X-NOT-HUMAN-READABLE flag +** subtype wrapping done automatically +** relies on X-NOT-HUMAN-READABLE flag * Added LDAP::Schema2 which is an extension of Ruby/LDAP::Schema - - made Schema#attr generic for easy type dereferencing +** made Schema#attr generic for easy type dereferencing * Updated rdoc in activeldap.rb * Updated examples (poorly) to reflect new functionality * Added several private helper functions @@ -557,8 +562,8 @@ h2. 0.4.0 h2. 0.3.6 * Fixed dn attribute value extraction on find and find_all - - these may have grabbed the wrong value if a DN attr has - multiple values. +** these may have grabbed the wrong value if a DN attr has + multiple values. * Fixed Base.search to return all values as arrays and update multivalued ones correctly * Lowered the amount of default logging to FATAL only @@ -591,26 +596,26 @@ h2. 0.3.0 * MORE API CHANGES (configuration.rb, etc) * Major overhaul to the internals! - - removed @@BLAH[@klass] in lieu of defining - class methods which contain the required values. This - allows for clean inheritance of Base subclasses! Whew! - - Added @@config to store the options currently in use - after a Base.connect - - Now cache passwords for doing reconnects - - dnattr now accessible to the outside as a class method only +** removed @@BLAH[@klass] in lieu of defining + class methods which contain the required values. This + allows for clean inheritance of Base subclasses! Whew! +** Added @@config to store the options currently in use + after a Base.connect +** Now cache passwords for doing reconnects +** dnattr now accessible to the outside as a class method only * Added Base.search to wrap normal LDAP search for convenience. - - This returns a hash of hashes with the results indexed first by - full dn, then by attribute. +** This returns a hash of hashes with the results indexed first by + full dn, then by attribute. h2. 0.2.0 * API CHANGES: - - Extension classes must be defined using map_to_ldap instead of setting - random values in initialize - - Base#find is now Base.find_all and is a class method - - Base.find returns the first match a la Array#find - - force_reload is gone in belongs_to and has_many created methods - - hiding Base.new, Base.find, and Base.find_all from direct access +** Extension classes must be defined using map_to_ldap instead of setting + random values in initialize +** Base#find is now Base.find_all and is a class method +** Base.find returns the first match a la Array#find +** force_reload is gone in belongs_to and has_many created methods +** hiding Base.new, Base.find, and Base.find_all from direct access * added uniq to setting objectClass to avoid stupid errors * fixed new object creation bug where attributes were added before the objectclass resulting in a violation (Base#write) @@ -658,7 +663,7 @@ h2. 0.1.2 * Log4r support * Better packaging (automated) * Work-around for SSL stupidity - - SSLConn doesn't check if the port it connected to is really using SSL! +** SSLConn doesn't check if the port it connected to is really using SSL! h2. 0.1.1 @@ -682,13 +687,13 @@ h2. 0.0.9 h2. 0.0.8 * Added user and group scripting examples - - usermod, userls, useradd, userdel - - groupmod, groupls +** usermod, userls, useradd, userdel +** groupmod, groupls h2. 0.0.7 * Cleaner authentication loop: - - SASL (GSSAPI only), simple, anonymous +** SASL (GSSAPI only), simple, anonymous * Added allow_anonymous option added (default: false) h2. 0.0.6 From null at cozmixng.org Thu Jul 7 20:01:43 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Fri, 08 Jul 2011 00:01:43 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] remove needless code. Message-ID: <20110708001055.612E82C42FC@taiyaki.ru> Kouhei Sutou 2011-07-08 00:01:43 +0000 (Fri, 08 Jul 2011) New Revision: 2e97e6175d69d365c08857b86522a65696adb6b0 Log: remove needless code. Modified files: Rakefile Modified: Rakefile (+0 -21) =================================================================== --- Rakefile 2011-07-08 00:01:14 +0000 (81c712a) +++ Rakefile 2011-07-08 00:01:43 +0000 (1c7ab65) @@ -110,27 +110,6 @@ relative_binary_dir = File.join("vendor", "local") vendor_dir = File.join(base_dir, relative_vendor_dir) binary_dir = File.join(base_dir, relative_binary_dir) -groonga_win32_i386_p = ENV["GROONGA32"] == "yes" - -Rake::ExtensionTask.new("groonga", spec) do |ext| - if groonga_win32_i386_p - ext.cross_platform = ["x86-mingw32", "i386-mswin32"] - else - ext.cross_platform = ["x64-mingw32"] - # ext.cross_platform << "x64-mswin64" # We need to build with VC++ 2010. :< - end - if windows? - ext.gem_spec.files += collect_binary_files(relative_binary_dir) - else - ext.cross_compile = true - ext.cross_compiling do |_spec| - if windows?(_spec.platform.to_s) - _spec.files += collect_binary_files(relative_binary_dir) - end - end - end -end - include ERB::Util def apply_template(content, paths, templates, language) From null at cozmixng.org Thu Jul 7 20:08:39 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Fri, 08 Jul 2011 00:08:39 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] [doc] move design text for Rails 3 support to doc/text/. Message-ID: <20110708001056.827BC2C431A@taiyaki.ru> Kouhei Sutou 2011-07-08 00:08:39 +0000 (Fri, 08 Jul 2011) New Revision: f754592cbe6c9f04b2b91b29e882ac321963eb7f Log: [doc] move design text for Rails 3 support to doc/text/. Renamed files: doc/text/development.textile (from design-for-rails3-support.txt) Renamed: doc/text/development.textile (+17 -3) 70% =================================================================== --- design-for-rails3-support.txt 2011-07-08 00:03:15 +0000 (f40ed1f) +++ doc/text/development.textile 2011-07-08 00:08:39 +0000 (69f7035) @@ -1,15 +1,29 @@ ---- must +h1. Development + +h2. Repository + +We are using +"GitHub":https://github.com/activeldap/activeldap as the +official repository. + +h2. Rails 3 support + +Here is design about Rails 3 support. + +h3. must + * We target to Rails 3.1.0. (Yes, it's not released yet but it will be released before we support Rails 3.x.) * We update the documentation and ensure that the procedure for including ActiveLdap in a Rails 3 project is correct. ---- may +h3. may + * We support Warden. * We support Devise * We support OmniAuth. (instead of Warden) ---- DONE +h3. DONE * We don't support Rails 3.0.x. * We provide active_ldap/railtie to initialize ActiveLdap. * We remove ActiveRecord dependency. From null at cozmixng.org Thu Jul 7 20:19:45 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Fri, 08 Jul 2011 00:19:45 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] [doc] don't document template files. Message-ID: <20110708002136.589D62C4156@taiyaki.ru> Kouhei Sutou 2011-07-08 00:19:45 +0000 (Fri, 08 Jul 2011) New Revision: 9d6310db143e2802fee8cd94293d5d457997b14d Log: [doc] don't document template files. Modified files: Rakefile Modified: Rakefile (+2 -1) =================================================================== --- Rakefile 2011-07-08 00:17:48 +0000 (10bf745) +++ Rakefile 2011-07-08 00:19:45 +0000 (23b4903) @@ -76,7 +76,8 @@ YARD::Rake::YardocTask.new do |task| task.options += ["--files", "doc/text/**/*"] task.options += ["--output-dir", doc_en_dir.to_s] task.options += ["--charset", "utf-8"] - task.files += FileList["lib/**/*.rb"] + template_files = FileList["lib/rails/generators/**/templates/*.rb"] + task.files += FileList["lib/**/*.rb"] - template_files end task :yard do From null at cozmixng.org Thu Jul 7 20:00:10 2011 From: null at cozmixng.org (null at cozmixng.org) Date: Fri, 08 Jul 2011 00:00:10 +0000 Subject: [activeldap-commit] activeldap/activeldap [master] [doc] move CHANGES to doc/text/news.textile. Message-ID: <20110708001054.CC4092C4155@taiyaki.ru> Kouhei Sutou 2011-07-08 00:00:10 +0000 (Fri, 08 Jul 2011) New Revision: e8cb60e7f36c92d87d4de9a6c38e34a22fb173c4 Log: [doc] move CHANGES to doc/text/news.textile. Modified files: .gitignore Gemfile Rakefile Renamed files: doc/text/news.textile (from CHANGES) Modified: .gitignore (+1 -1) =================================================================== --- .gitignore 2011-06-03 00:20:13 +0000 (b8c79f3) +++ .gitignore 2011-07-08 00:00:10 +0000 (125e89f) @@ -1,5 +1,5 @@ Gemfile.lock /test/.test-result/ /test/config.yaml -/doc/ +/doc/reference/ /pkg/ Modified: Gemfile (+1 -0) =================================================================== --- Gemfile 2011-06-03 00:20:13 +0000 (09a7a74) +++ Gemfile 2011-07-08 00:00:10 +0000 (49a1e7f) @@ -13,4 +13,5 @@ group :development, :test do gem 'jeweler' gem 'test-unit' gem 'test-unit-notify' + gem "yard" end Modified: Rakefile (+257 -9) =================================================================== --- Rakefile 2011-06-03 00:20:13 +0000 (68d9dad) +++ Rakefile 2011-07-08 00:00:10 +0000 (1fb33b8) @@ -8,6 +8,7 @@ require 'bundler/setup' require 'jeweler' require 'rake/testtask' +require 'yard' if YAML.const_defined?(:ENGINE) begin @@ -35,7 +36,7 @@ Jeweler::Tasks.new do |_spec| spec.files = FileList["lib/**/*", "{benchmark,examples,po}/**/*", "bin/*", - "CHANGES", + "doc/text/**/*", "COPYING", "Gemfile", "LICENSE", @@ -64,26 +65,273 @@ rescue LoadError puts "gettext_i18n_rails is not installed, you probably should run 'rake gems:install' or 'bundle install'." end +reference_base_dir = Pathname.new("doc/reference") +doc_en_dir = reference_base_dir + "en" +html_base_dir = Pathname.new("doc/html") +html_reference_dir = html_base_dir + spec.name +YARD::Rake::YardocTask.new do |task| + task.options += ["--title", "#{spec.name} - #{version}"] + # task.options += ["--charset", "UTF-8"] + task.options += ["--readme", "README.textile"] + task.options += ["--files", "doc/text/**/*"] + task.options += ["--output-dir", doc_en_dir.to_s] + task.options += ["--charset", "utf-8"] + task.files += FileList["lib/**/*.rb"] +end + +task :yard do + doc_en_dir.find do |path| + next if path.extname != ".html" + html = path.read + html = html.gsub(/