treequel 1.0.1 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/ChangeLog +176 -14
- data/LICENSE +1 -1
- data/Rakefile +61 -45
- data/Rakefile.local +20 -0
- data/bin/treequel +502 -269
- data/examples/ldap-rack-auth.rb +2 -0
- data/lib/treequel.rb +221 -18
- data/lib/treequel/branch.rb +410 -201
- data/lib/treequel/branchcollection.rb +25 -13
- data/lib/treequel/branchset.rb +42 -40
- data/lib/treequel/constants.rb +233 -3
- data/lib/treequel/control.rb +95 -0
- data/lib/treequel/controls/contentsync.rb +138 -0
- data/lib/treequel/controls/pagedresults.rb +162 -0
- data/lib/treequel/controls/sortedresults.rb +216 -0
- data/lib/treequel/directory.rb +212 -65
- data/lib/treequel/exceptions.rb +11 -12
- data/lib/treequel/filter.rb +1 -12
- data/lib/treequel/mixins.rb +83 -47
- data/lib/treequel/monkeypatches.rb +29 -0
- data/lib/treequel/schema.rb +23 -19
- data/lib/treequel/schema/attributetype.rb +33 -3
- data/lib/treequel/schema/ldapsyntax.rb +0 -11
- data/lib/treequel/schema/matchingrule.rb +0 -11
- data/lib/treequel/schema/matchingruleuse.rb +0 -11
- data/lib/treequel/schema/objectclass.rb +36 -10
- data/lib/treequel/schema/table.rb +159 -0
- data/lib/treequel/sequel_integration.rb +7 -7
- data/lib/treequel/utils.rb +4 -66
- data/rake/documentation.rb +89 -0
- data/rake/helpers.rb +375 -307
- data/rake/hg.rb +16 -2
- data/rake/manual.rb +11 -6
- data/rake/packaging.rb +20 -35
- data/rake/publishing.rb +22 -62
- data/spec/lib/constants.rb +20 -0
- data/spec/lib/control_behavior.rb +44 -0
- data/spec/lib/matchers.rb +51 -0
- data/spec/treequel/branch_spec.rb +88 -29
- data/spec/treequel/branchcollection_spec.rb +24 -1
- data/spec/treequel/branchset_spec.rb +123 -51
- data/spec/treequel/control_spec.rb +48 -0
- data/spec/treequel/controls/contentsync_spec.rb +38 -0
- data/spec/treequel/controls/pagedresults_spec.rb +138 -0
- data/spec/treequel/controls/sortedresults_spec.rb +171 -0
- data/spec/treequel/directory_spec.rb +186 -16
- data/spec/treequel/mixins_spec.rb +42 -3
- data/spec/treequel/schema/attributetype_spec.rb +22 -20
- data/spec/treequel/schema/objectclass_spec.rb +67 -46
- data/spec/treequel/schema/table_spec.rb +134 -0
- data/spec/treequel_spec.rb +277 -15
- metadata +89 -108
- data/bin/treequel.orig +0 -963
- data/examples/ldap-monitor.rb +0 -143
- data/examples/ldap-monitor/public/css/master.css +0 -328
- data/examples/ldap-monitor/public/images/card_small.png +0 -0
- data/examples/ldap-monitor/public/images/chain_small.png +0 -0
- data/examples/ldap-monitor/public/images/globe_small.png +0 -0
- data/examples/ldap-monitor/public/images/globe_small_green.png +0 -0
- data/examples/ldap-monitor/public/images/plug.png +0 -0
- data/examples/ldap-monitor/public/images/shadows/large-30-down.png +0 -0
- data/examples/ldap-monitor/public/images/tick.png +0 -0
- data/examples/ldap-monitor/public/images/tick_circle.png +0 -0
- data/examples/ldap-monitor/public/images/treequel-favicon.png +0 -0
- data/examples/ldap-monitor/views/backends.erb +0 -41
- data/examples/ldap-monitor/views/connections.erb +0 -74
- data/examples/ldap-monitor/views/databases.erb +0 -39
- data/examples/ldap-monitor/views/dump_subsystem.erb +0 -14
- data/examples/ldap-monitor/views/index.erb +0 -14
- data/examples/ldap-monitor/views/layout.erb +0 -35
- data/examples/ldap-monitor/views/listeners.erb +0 -30
- data/rake/rdoc.rb +0 -30
- data/rake/win32.rb +0 -190
data/ChangeLog
CHANGED
@@ -1,4 +1,166 @@
|
|
1
|
-
|
1
|
+
261[tip] 0188c2ba5b7e 2010-07-07 23:21 -0700 ged
|
2
|
+
Added tag 1.0.4 for changeset 0ec4ff0ce67f
|
3
|
+
|
4
|
+
260[1.0.4] 0ec4ff0ce67f 2010-07-07 23:21 -0700 ged
|
5
|
+
Added signature for changeset c8534439a5bc
|
6
|
+
|
7
|
+
259 c8534439a5bc 2010-07-07 23:20 -0700 ged
|
8
|
+
Bumping version to 1.0.4 because I'm an idiot and included some files that were intended for a future version in 1.0.3.
|
9
|
+
|
10
|
+
258 47bb9cd7af3b 2010-07-07 22:32 -0700 ged
|
11
|
+
Added tag 1.0.3 for changeset 65be21a77bfe
|
12
|
+
|
13
|
+
257[1.0.3] 65be21a77bfe 2010-07-07 22:32 -0700 ged
|
14
|
+
Added signature for changeset fd86e30957a6
|
15
|
+
|
16
|
+
256 fd86e30957a6 2010-07-07 19:04 -0700 ged
|
17
|
+
Build system update, prep for 1.0.3 release.
|
18
|
+
|
19
|
+
255 dd880dcd1b9a 2010-06-14 16:18 -0700 ged
|
20
|
+
Fix the 'parent' command in the treequel shell and the success message for the 'cp' command.
|
21
|
+
|
22
|
+
254 c2a696248d22 2010-06-14 15:58 -0700 ged
|
23
|
+
Treequel shell cleanup, new subcommand, Treequel::Directory#bound_user
|
24
|
+
|
25
|
+
253 61d5aae13b7e 2010-06-10 15:11 -0700 ged
|
26
|
+
Added 'cp' treequel shell command, removed FOLDED_LDIF_ATTRVAL_SPEC pattern.
|
27
|
+
|
28
|
+
252 d9073c3a9f0e 2010-05-27 05:56 -0700 ged
|
29
|
+
Treequel shell cleanup, support config-loaded directory, Branch#move fixes
|
30
|
+
|
31
|
+
251 0982bb19bfb9 2010-05-03 15:04 -0700 ged
|
32
|
+
Treequel shell work, made schema tables more Hash-like.
|
33
|
+
|
34
|
+
250 b725e5424fa9 2010-04-14 14:33 -0700 ged
|
35
|
+
Fixed a bug in Treequel.read_opts_from_config which caused
|
36
|
+
|
37
|
+
249 561646be1b80 2010-04-13 16:49 -0700 ged
|
38
|
+
More YARD docs
|
39
|
+
|
40
|
+
248 94b428852c7a 2010-04-11 20:29 -0700 ged
|
41
|
+
Fixed LDIF and highlighting in treequel shell
|
42
|
+
|
43
|
+
247 a42d7297577a 2010-04-10 09:24 -0700 ged
|
44
|
+
Updated build system.
|
45
|
+
|
46
|
+
246 a039187fcbfd 2010-04-08 15:14 -0700 ged
|
47
|
+
Updated build system, more YARDificiation.
|
48
|
+
|
49
|
+
245 b54fe9c1171d 2010-04-07 09:14 -0700 ged
|
50
|
+
Updated build system.
|
51
|
+
|
52
|
+
244 96125f5e3297 2010-04-07 09:05 -0700 ged
|
53
|
+
More specs, more YARD docs.
|
54
|
+
|
55
|
+
243 91486cbc9047 2010-04-06 18:52 -0700 ged
|
56
|
+
New method Treequel::Branch#values_at, rewrote #delete to be consistent with Hash#delete.
|
57
|
+
|
58
|
+
242 bc24a82b0e9c 2010-03-23 15:11 -0700 ged
|
59
|
+
Added NSS-style ldap.conf support.
|
60
|
+
|
61
|
+
241 2f756d5f12e2 2010-03-19 11:05 -0700 ged
|
62
|
+
Converted hash-based schema tables to a case-insensitive Table class (fixes #1)
|
63
|
+
|
64
|
+
240 f8de798625ee 2010-03-18 15:18 -0700 ged
|
65
|
+
Adding system-config methods to the Treequel methods
|
66
|
+
|
67
|
+
239 02660115ea46 2010-03-02 12:48 -0800 ged
|
68
|
+
Finished specs for BranchCollection#empty?
|
69
|
+
|
70
|
+
238 cbdb4342dc46 2010-03-01 18:17 -0800 ged
|
71
|
+
Treequel shell bugfixes, #empty? on Branchsets and BranchCollections
|
72
|
+
|
73
|
+
237 5af1ee6a7f6c 2010-02-17 18:18 -0800 ged
|
74
|
+
Added an 'irb' command to the treequel shell, fixed build-number parsing.
|
75
|
+
|
76
|
+
236 8a43b642fd91 2010-02-09 16:37 -0800 ged
|
77
|
+
Implemented the `-b bind_dn` option.
|
78
|
+
|
79
|
+
235:234,233 2a1bac85c038 2010-02-03 18:24 -0800 ged
|
80
|
+
Merged 233:1d06d28159a6
|
81
|
+
|
82
|
+
234:232 e96bbf2e7325 2010-02-03 18:23 -0800 ged
|
83
|
+
Adding the beginnings of ActiveDirectory support, treequel shell options, server introspection.
|
84
|
+
|
85
|
+
233:230,232 1d06d28159a6 2010-01-26 10:56 -0800 ged
|
86
|
+
Merged with 230:b994d8d9d608
|
87
|
+
|
88
|
+
232 8b2fb7415412 2010-01-26 10:55 -0800 ged
|
89
|
+
Initial (untested) implementation of the sorted results control.
|
90
|
+
|
91
|
+
231:229 84087b01d473 2010-01-13 20:12 -0800 ged
|
92
|
+
Make treequel shell's 'cat' command error for non-existant entries
|
93
|
+
|
94
|
+
230 b994d8d9d608 2010-01-24 12:57 -0800 ged
|
95
|
+
Convert the option parsers to a class global instead of a constant
|
96
|
+
|
97
|
+
229 669a09149f48 2010-01-13 11:36 -0800 ged
|
98
|
+
Fix the 'grep' command in the Treequel shell.
|
99
|
+
|
100
|
+
228 ab2a2ff43b60 2010-01-12 10:12 -0800 ged
|
101
|
+
Operational attributes propagation and treequel shell fixes.
|
102
|
+
|
103
|
+
227:226,223 14f5f723d0aa 2010-01-07 16:43 -0800 ged
|
104
|
+
Merged with d77a0bf26034
|
105
|
+
|
106
|
+
226 00ac1bc4e917 2010-01-07 16:42 -0800 ged
|
107
|
+
Updated build system
|
108
|
+
|
109
|
+
225 5afefa230ef0 2010-01-07 16:41 -0800 ged
|
110
|
+
Improvements to the treequel shell, fixes for 1.9.1.
|
111
|
+
|
112
|
+
224:221 83b178f0850e 2010-01-06 19:24 -0800 ged
|
113
|
+
Eliminate duplicates when smushing RDN attributes on a Treequel::Directory#create
|
114
|
+
|
115
|
+
223 d77a0bf26034 2009-12-22 15:13 -0800 ged
|
116
|
+
Reworked LDIF display colors in the shell to be more visible.
|
117
|
+
|
118
|
+
222 9aeccec1ee84 2009-12-22 15:02 -0800 ged
|
119
|
+
Make the treequel shell fall back to plain connect (with a warning) if TLS fails.
|
120
|
+
|
121
|
+
221:219,220 3bdd645530fe 2009-12-22 09:40 -0800 ged
|
122
|
+
Automated merge with ssh://hg@deveiate/Treequel
|
123
|
+
|
124
|
+
220:217 31c326800cc6 2009-12-22 09:40 -0800 ged
|
125
|
+
Treequel shell fix, splitting off the LDAP monitor example, version bump.
|
126
|
+
|
127
|
+
219:218,217 9571c9d8e4dd 2009-12-18 10:23 -0800 ged
|
128
|
+
Merged with 5fd4033e1556
|
129
|
+
|
130
|
+
218:216 ffc2ebacdfd0 2009-12-17 21:50 -0800 ged
|
131
|
+
More controls work, started several more control modules.
|
132
|
+
|
133
|
+
217 5fd4033e1556 2009-12-16 11:24 -0800 ged
|
134
|
+
Updated build system, normalized comments in mixins.rb.
|
135
|
+
|
136
|
+
216 b04972837e63 2009-12-11 18:47 -0800 ged
|
137
|
+
More work on controls,
|
138
|
+
|
139
|
+
215 d1ef2c0f53f2 2009-12-08 09:28 -0800 ged
|
140
|
+
Finished initial Controls implementation, added PagedResultsControl.
|
141
|
+
|
142
|
+
214 b937fbec04ca 2009-12-07 17:11 -0800 mahlon
|
143
|
+
Add scaffolding for Treequel::Control.
|
144
|
+
|
145
|
+
213 30f67c57d0bb 2009-12-07 16:41 -0800 ged
|
146
|
+
Law of Demeter fix and more work on the controls spike.
|
147
|
+
|
148
|
+
212 014435b07b2d 2009-12-06 22:13 -0800 ged
|
149
|
+
Fixed the shell 'edit' command, cleaned up LDIF output, dependency fixes.
|
150
|
+
|
151
|
+
211 b259ac7d021e 2009-12-06 14:59 -0800 ged
|
152
|
+
Adding '+' mode to 'cat' (stolen from shelldap)
|
153
|
+
|
154
|
+
210 150d5cf819a9 2009-12-01 10:25 -0800 mahlon
|
155
|
+
Heh heh heh, he said 'fem'
|
156
|
+
|
157
|
+
209 ff8226a744d8 2009-11-17 20:38 -0800 ged
|
158
|
+
Added tag 1.0.1 for changeset 9c9993ba908e
|
159
|
+
|
160
|
+
208[1.0.1] 9c9993ba908e 2009-11-17 20:38 -0800 ged
|
161
|
+
Added signature for changeset c5e4cb039999
|
162
|
+
|
163
|
+
207 c5e4cb039999 2009-11-17 20:35 -0800 ged
|
2
164
|
Added Branchset#as, added 'yaml'/disabled 'edit' command in treequel shell
|
3
165
|
|
4
166
|
206 67502a7b9224 2009-11-17 15:58 -0800 ged
|
@@ -334,36 +496,36 @@
|
|
334
496
|
96 6b5358420802 2009-07-31 08:29 -0700 ged
|
335
497
|
Updated build system
|
336
498
|
|
337
|
-
95:94
|
499
|
+
95:93,94 a5e715f5f877 2009-07-31 08:13 -0700 ged
|
338
500
|
Merged. Someday I'll get the hang of this.
|
339
501
|
|
340
|
-
94:
|
502
|
+
94:91 46e6dce0c011 2009-07-29 13:28 -0700 ged
|
503
|
+
* Adding coverage cache to the ignorefile.
|
504
|
+
|
505
|
+
93:92,91 395b7bf6f248 2009-07-28 06:11 -0700 ged
|
341
506
|
Merged with 34cc97817266
|
342
507
|
|
343
|
-
|
508
|
+
92:88 89f74035c67d 2009-07-28 06:10 -0700 ged
|
344
509
|
Manual rewording, .hgignore updates
|
345
510
|
|
346
|
-
92 46e6dce0c011 2009-07-29 13:28 -0700 ged
|
347
|
-
* Adding coverage cache to the ignorefile.
|
348
|
-
|
349
511
|
91 34cc97817266 2009-07-27 12:06 -0700 ged
|
350
512
|
Updated build system
|
351
513
|
|
352
|
-
90:
|
514
|
+
90:89,88 daf0e44c41ac 2009-07-27 11:58 -0700 ged
|
353
515
|
Merging work from gont
|
354
516
|
|
355
|
-
89:83
|
517
|
+
89:83 fc3c3bac2c22 2009-07-24 17:27 -0700 ged
|
518
|
+
Unlinking the subrepo, as it doesn't behave well enough quite yet.
|
519
|
+
|
520
|
+
88:83,87 b7a919b2ad5d 2009-07-24 21:07 -0700 ged
|
356
521
|
Merging build system fixes
|
357
522
|
|
358
|
-
|
523
|
+
87 620807d4c6d5 2009-07-24 21:05 -0700 ged
|
359
524
|
Updated build system
|
360
525
|
|
361
|
-
|
526
|
+
86 f631900a9ad8 2009-07-24 19:33 -0700 ged
|
362
527
|
Removing subrepo, as it doesn't work quite the way I'd hoped.
|
363
528
|
|
364
|
-
86:83 fc3c3bac2c22 2009-07-24 17:27 -0700 ged
|
365
|
-
Unlinking the subrepo, as it doesn't behave well enough quite yet.
|
366
|
-
|
367
529
|
85 65236b2101e5 2009-07-24 11:22 -0700 ged
|
368
530
|
Initial commit of Mercurial-based tasks
|
369
531
|
|
data/LICENSE
CHANGED
data/Rakefile
CHANGED
@@ -1,22 +1,22 @@
|
|
1
|
-
#!rake
|
1
|
+
#!rake -*- ruby -*-
|
2
2
|
#
|
3
3
|
# Treequel rakefile
|
4
4
|
#
|
5
5
|
# Based on various other Rakefiles, especially one by Ben Bleything
|
6
6
|
#
|
7
|
-
# Copyright (c) 2007-
|
7
|
+
# Copyright (c) 2007-2010 The FaerieMUD Consortium
|
8
8
|
#
|
9
9
|
# Authors:
|
10
10
|
# * Michael Granger <ged@FaerieMUD.org>
|
11
|
-
# * Mahlon E. Smith <mahlon@martini.nu>
|
12
11
|
#
|
13
12
|
|
14
13
|
BEGIN {
|
14
|
+
require 'rbconfig'
|
15
15
|
require 'pathname'
|
16
16
|
basedir = Pathname.new( __FILE__ ).dirname
|
17
17
|
|
18
18
|
libdir = basedir + "lib"
|
19
|
-
extdir =
|
19
|
+
extdir = libdir + Config::CONFIG['sitearch']
|
20
20
|
|
21
21
|
$LOAD_PATH.unshift( libdir.to_s ) unless $LOAD_PATH.include?( libdir.to_s )
|
22
22
|
$LOAD_PATH.unshift( extdir.to_s ) unless $LOAD_PATH.include?( extdir.to_s )
|
@@ -34,7 +34,7 @@ rescue LoadError
|
|
34
34
|
end
|
35
35
|
|
36
36
|
begin
|
37
|
-
require '
|
37
|
+
require 'rubygems'
|
38
38
|
rescue LoadError
|
39
39
|
module Gem
|
40
40
|
class Specification; end
|
@@ -74,10 +74,10 @@ if VERSION_FILE.exist? && buildrev = ENV['CC_BUILD_LABEL']
|
|
74
74
|
PKG_VERSION = VERSION_FILE.read[ /VERSION\s*=\s*['"](\d+\.\d+\.\d+)['"]/, 1 ] + '.' + buildrev
|
75
75
|
elsif VERSION_FILE.exist?
|
76
76
|
PKG_VERSION = VERSION_FILE.read[ /VERSION\s*=\s*['"](\d+\.\d+\.\d+)['"]/, 1 ]
|
77
|
-
else
|
78
|
-
PKG_VERSION = '0.0.0'
|
79
77
|
end
|
80
78
|
|
79
|
+
PKG_VERSION = '0.0.0' unless defined?( PKG_VERSION )
|
80
|
+
|
81
81
|
PKG_FILE_NAME = "#{PKG_NAME.downcase}-#{PKG_VERSION}"
|
82
82
|
GEM_FILE_NAME = "#{PKG_FILE_NAME}.gem"
|
83
83
|
|
@@ -91,7 +91,7 @@ EXTCONF = EXTDIR + 'extconf.rb'
|
|
91
91
|
|
92
92
|
ARTIFACTS_DIR = Pathname.new( CC_BUILD_ARTIFACTS )
|
93
93
|
|
94
|
-
TEXT_FILES = Rake::FileList.new( %w[Rakefile ChangeLog README LICENSE] )
|
94
|
+
TEXT_FILES = Rake::FileList.new( %w[Rakefile ChangeLog README* LICENSE] )
|
95
95
|
BIN_FILES = Rake::FileList.new( "#{BINDIR}/*" )
|
96
96
|
LIB_FILES = Rake::FileList.new( "#{LIBDIR}/**/*.rb" )
|
97
97
|
EXT_FILES = Rake::FileList.new( "#{EXTDIR}/**/*.{c,h,rb}" )
|
@@ -129,6 +129,10 @@ RELEASE_FILES = TEXT_FILES +
|
|
129
129
|
|
130
130
|
RELEASE_FILES << LOCAL_RAKEFILE.to_s if LOCAL_RAKEFILE.exist?
|
131
131
|
|
132
|
+
RELEASE_ANNOUNCE_ADDRESSES = [
|
133
|
+
"Ruby-Talk List <ruby-talk@ruby-lang.org>",
|
134
|
+
]
|
135
|
+
|
132
136
|
COVERAGE_MINIMUM = ENV['COVERAGE_MINIMUM'] ? Float( ENV['COVERAGE_MINIMUM'] ) : 85.0
|
133
137
|
RCOV_EXCLUDES = 'spec,tests,/Library/Ruby,/var/lib,/usr/local/lib'
|
134
138
|
RCOV_OPTS = [
|
@@ -148,7 +152,7 @@ if !RAKE_TASKDIR.exist?
|
|
148
152
|
|
149
153
|
if ans =~ /^y/i
|
150
154
|
$stderr.puts "Okay, fetching #{RAKE_TASKLIBS_URL} into #{RAKE_TASKDIR}..."
|
151
|
-
system 'hg', 'clone', RAKE_TASKLIBS_URL, RAKE_TASKDIR
|
155
|
+
system 'hg', 'clone', RAKE_TASKLIBS_URL, "./#{RAKE_TASKDIR}"
|
152
156
|
if ! $?.success?
|
153
157
|
fail "Damn. That didn't work. Giving up; maybe try manually fetching?"
|
154
158
|
end
|
@@ -161,30 +165,41 @@ if !RAKE_TASKDIR.exist?
|
|
161
165
|
end
|
162
166
|
|
163
167
|
require RAKE_TASKDIR + 'helpers.rb'
|
168
|
+
include RakefileHelpers
|
164
169
|
|
165
|
-
#
|
170
|
+
# Set the build ID if the mercurial executable is available
|
166
171
|
if hg = which( 'hg' )
|
167
172
|
id = IO.read('|-') or exec hg.to_s, 'id', '-n'
|
168
|
-
PKG_BUILD = id.chomp[ /^[[:xdigit:]]+/ ]
|
173
|
+
PKG_BUILD = "pre%03d" % [(id.chomp[ /^[[:xdigit:]]+/ ] || '1')]
|
169
174
|
else
|
170
|
-
PKG_BUILD =
|
175
|
+
PKG_BUILD = 'pre000'
|
171
176
|
end
|
172
177
|
SNAPSHOT_PKG_NAME = "#{PKG_FILE_NAME}.#{PKG_BUILD}"
|
173
178
|
SNAPSHOT_GEM_NAME = "#{SNAPSHOT_PKG_NAME}.gem"
|
174
179
|
|
175
180
|
# Documentation constants
|
176
|
-
|
181
|
+
API_DOCSDIR = DOCSDIR + 'api'
|
182
|
+
README_FILE = TEXT_FILES.find {|path| path =~ /^README/ } || 'README'
|
177
183
|
RDOC_OPTIONS = [
|
178
|
-
'-
|
179
|
-
'-
|
180
|
-
'
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
+
'--tab-width=4',
|
185
|
+
'--show-hash',
|
186
|
+
'--include', BASEDIR.to_s,
|
187
|
+
"--main=#{README_FILE}",
|
188
|
+
"--title=#{PKG_NAME}",
|
189
|
+
]
|
190
|
+
YARD_OPTIONS = [
|
191
|
+
'--use-cache',
|
192
|
+
'--no-private',
|
193
|
+
'--protected',
|
194
|
+
'-r', README_FILE,
|
195
|
+
'--exclude', 'extconf\\.rb',
|
196
|
+
'--files', 'ChangeLog,LICENSE',
|
197
|
+
'--output-dir', API_DOCSDIR.to_s,
|
198
|
+
'--title', "#{PKG_NAME} #{PKG_VERSION}",
|
184
199
|
]
|
185
200
|
|
186
201
|
# Release constants
|
187
|
-
SMTP_HOST =
|
202
|
+
SMTP_HOST = "mail.faeriemud.org"
|
188
203
|
SMTP_PORT = 465 # SMTP + SSL
|
189
204
|
|
190
205
|
# Project constants
|
@@ -194,31 +209,27 @@ PROJECT_DOCDIR = "#{PROJECT_PUBDIR}/#{PKG_NAME}"
|
|
194
209
|
PROJECT_SCPPUBURL = "#{PROJECT_HOST}:#{PROJECT_PUBDIR}"
|
195
210
|
PROJECT_SCPDOCURL = "#{PROJECT_HOST}:#{PROJECT_DOCDIR}"
|
196
211
|
|
197
|
-
# Rubyforge stuff
|
198
|
-
RUBYFORGE_GROUP = 'deveiate'
|
199
|
-
RUBYFORGE_PROJECT = 'treequel'
|
200
|
-
|
201
212
|
# Gem dependencies: gemname => version
|
202
213
|
DEPENDENCIES = {
|
203
|
-
'termios' => '>= 0.9.4',
|
204
|
-
'columnize' => '>= 0.3.1',
|
205
|
-
'ruby-terminfo' => '>= 0.1.1',
|
206
214
|
'ruby-ldap' => '>= 0.9.9',
|
207
215
|
}
|
208
216
|
|
209
217
|
# Developer Gem dependencies: gemname => version
|
210
218
|
DEVELOPMENT_DEPENDENCIES = {
|
211
|
-
'rake'
|
212
|
-
'rcodetools'
|
213
|
-
'rcov'
|
214
|
-
'rdoc'
|
215
|
-
'RedCloth'
|
216
|
-
'rspec'
|
217
|
-
'
|
218
|
-
'
|
219
|
-
'
|
220
|
-
'
|
221
|
-
'
|
219
|
+
'rake' => '>= 0.8.7',
|
220
|
+
'rcodetools' => '>= 0.7.0.0',
|
221
|
+
'rcov' => '>= 0.8.1.2.0',
|
222
|
+
'rdoc' => '>= 2.4.3',
|
223
|
+
'RedCloth' => '>= 4.0.3',
|
224
|
+
'rspec' => '>= 1.2.6',
|
225
|
+
'ruby-termios' => '>= 0.9.6',
|
226
|
+
'text-format' => '>= 1.0.0',
|
227
|
+
'tmail' => '>= 1.2.3.1',
|
228
|
+
'diff-lcs' => '>= 1.1.2',
|
229
|
+
'termios' => '>= 0.9.4',
|
230
|
+
'columnize' => '>= 0.3.1',
|
231
|
+
'diff-lcs' => '>= 1.1.2',
|
232
|
+
'ruby-terminfo' => '>= 0.1.1',
|
222
233
|
}
|
223
234
|
|
224
235
|
# Non-gem requirements: packagename => version
|
@@ -237,17 +248,22 @@ GEMSPEC = Gem::Specification.new do |gem|
|
|
237
248
|
"the impedence mismatch of trying to treat LDAP as if it's a relational database, and",
|
238
249
|
"instead embrace its hierarchical, free-form nature.",
|
239
250
|
].join( "\n" )
|
251
|
+
gem.post_install_message = [
|
252
|
+
"If you want to use the included 'treequel' LDAP shell, you'll need to install",
|
253
|
+
"the following libraries as well:",
|
254
|
+
" - termios",
|
255
|
+
" - ruby-terminfo",
|
256
|
+
" - columnize",
|
257
|
+
" - diff-lcs",
|
258
|
+
].join( "\n" )
|
240
259
|
|
241
260
|
gem.authors = "Michael Granger, Mahlon E. Smith"
|
242
261
|
gem.email = ["mahlon@martini.nu", "ged@FaerieMUD.org"]
|
243
262
|
gem.homepage = 'http://deveiate.org/projects/Treequel'
|
244
263
|
|
245
|
-
# Apparently this isn't actually the 'project'?
|
246
|
-
gem.rubyforge_project = RUBYFORGE_GROUP
|
247
|
-
|
248
264
|
gem.has_rdoc = true
|
249
265
|
gem.rdoc_options = RDOC_OPTIONS
|
250
|
-
gem.extra_rdoc_files =
|
266
|
+
gem.extra_rdoc_files = TEXT_FILES - [ 'Rakefile' ]
|
251
267
|
|
252
268
|
gem.bindir = BINDIR.relative_path_from(BASEDIR).to_s
|
253
269
|
gem.executables = BIN_FILES.select {|pn| File.executable?(pn) }.
|
@@ -301,14 +317,14 @@ import LOCAL_RAKEFILE if LOCAL_RAKEFILE.exist?
|
|
301
317
|
#####################################################################
|
302
318
|
|
303
319
|
### Default task
|
304
|
-
task :default => [:clean, :local, :spec, :
|
320
|
+
task :default => [:clean, :local, :spec, :apidocs, :package]
|
305
321
|
|
306
322
|
### Task the local Rakefile can append to -- no-op by default
|
307
323
|
task :local
|
308
324
|
|
309
325
|
### Task: clean
|
310
|
-
CLEAN.include 'coverage'
|
311
|
-
CLOBBER.include 'artifacts', 'coverage.info', PKGDIR
|
326
|
+
CLEAN.include 'coverage', '**/*.orig', '**/*.rej'
|
327
|
+
CLOBBER.include 'artifacts', 'coverage.info', 'ChangeLog', PKGDIR
|
312
328
|
|
313
329
|
### Task: changelog
|
314
330
|
file 'ChangeLog' do |task|
|
data/Rakefile.local
CHANGED
@@ -14,6 +14,7 @@ require 'pp'
|
|
14
14
|
MANUAL_PAGES = Pathname.glob( MANUALDIR + '**/*.page' )
|
15
15
|
|
16
16
|
task :local => :check_manual
|
17
|
+
task :manual => :check_manual
|
17
18
|
|
18
19
|
# Check the manual for laika references before committing
|
19
20
|
Rake::Task[ 'checkin' ].prerequisites.unshift( 'check_manual' )
|
@@ -40,4 +41,23 @@ task :check_manual => MANUAL_PAGES do
|
|
40
41
|
end
|
41
42
|
end
|
42
43
|
|
44
|
+
namespace :spec do
|
45
|
+
desc "Run specs under gdb"
|
46
|
+
task :gdb do |task|
|
47
|
+
require 'tempfile'
|
48
|
+
|
49
|
+
cmd_parts = ['run']
|
50
|
+
cmd_parts << '-Ilib:ext'
|
51
|
+
cmd_parts << '/usr/bin/spec'
|
52
|
+
cmd_parts += SPEC_FILES.collect { |fn| %["#{fn}"] }
|
53
|
+
cmd_parts += COMMON_SPEC_OPTS + ['-f', 's', '-c']
|
54
|
+
|
55
|
+
script = Tempfile.new( 'spec-gdbscript' )
|
56
|
+
script.puts( cmd_parts.join(' ') )
|
57
|
+
script.flush
|
58
|
+
|
59
|
+
run 'gdb', '-x', script.path, RUBY
|
60
|
+
end
|
61
|
+
end
|
62
|
+
|
43
63
|
|