hoe 1.5.1 → 1.5.2
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/History.txt +13 -0
- data/README.txt +1 -1
- data/Rakefile +4 -1
- data/bin/sow +0 -0
- data/lib/hoe.rb +45 -18
- metadata +4 -4
data/History.txt
CHANGED
@@ -1,3 +1,16 @@
|
|
1
|
+
=== 1.5.2 / 2008-05-20
|
2
|
+
|
3
|
+
* 4 Minor Enhancements:
|
4
|
+
|
5
|
+
* Added multiruby_skip attribute for 'rake multi' version invalidation.
|
6
|
+
* Improved error messages when files are missing.
|
7
|
+
* Added rubygems post_install_message accessor. Thanks to Dr. Nic.
|
8
|
+
* Cleaned up alternative_name... I didn't get it.
|
9
|
+
|
10
|
+
* 1 Bug Fix:
|
11
|
+
|
12
|
+
* Removed require of rake/contrib/sshpublisher to fix 1.9.
|
13
|
+
|
1
14
|
=== 1.5.1 / 2008-03-04
|
2
15
|
|
3
16
|
* 2 Minor Enhancements:
|
data/README.txt
CHANGED
@@ -69,7 +69,7 @@ or
|
|
69
69
|
|
70
70
|
(The MIT License)
|
71
71
|
|
72
|
-
Copyright (c)
|
72
|
+
Copyright (c) Ryan Davis, Zen Spider Software
|
73
73
|
|
74
74
|
Permission is hereby granted, free of charge, to any person obtaining
|
75
75
|
a copy of this software and associated documentation files (the
|
data/Rakefile
CHANGED
@@ -5,11 +5,14 @@ require './lib/hoe.rb'
|
|
5
5
|
Hoe.new("hoe", Hoe::VERSION) do |hoe|
|
6
6
|
hoe.rubyforge_name = "seattlerb"
|
7
7
|
hoe.developer("Ryan Davis", "ryand-ruby@zenspider.com")
|
8
|
+
|
9
|
+
hoe.multiruby_skip << "rubinius"
|
8
10
|
end
|
9
11
|
|
12
|
+
desc "Generate a list of tasks for doco. RDOC=1 for commented output"
|
10
13
|
task :tasks do
|
11
14
|
tasks = `rake -T`.scan(/rake (\w+)\s+# (.*)/)
|
12
|
-
tasks.reject! { |t,d| t =~ /^(clobber|re(package|docs))/ }
|
15
|
+
tasks.reject! { |t,d| t =~ /^(clobber|tasks|re(package|docs))/ }
|
13
16
|
max = tasks.map { |x,y| x.size }.max
|
14
17
|
|
15
18
|
tasks.each do |t,d|
|
data/bin/sow
CHANGED
File without changes
|
data/lib/hoe.rb
CHANGED
@@ -2,7 +2,6 @@
|
|
2
2
|
|
3
3
|
require 'rubygems'
|
4
4
|
require 'rake'
|
5
|
-
require 'rake/contrib/sshpublisher'
|
6
5
|
require 'rake/gempackagetask'
|
7
6
|
require 'rake/rdoctask'
|
8
7
|
require 'rake/testtask'
|
@@ -64,8 +63,8 @@ require 'yaml'
|
|
64
63
|
# exclude:: A regular expression of files to exclude from
|
65
64
|
# +check_manifest+.
|
66
65
|
# publish_on_announce:: Run +publish_docs+ when you run +release+.
|
67
|
-
# signing_key_file::
|
68
|
-
# signing_cert_file::
|
66
|
+
# signing_key_file:: Signs your gems with this private key.
|
67
|
+
# signing_cert_file:: Signs your gem with this certificate.
|
69
68
|
# blogs:: An array of hashes of blog settings.
|
70
69
|
#
|
71
70
|
# Run +config_hoe+ and see ~/.hoerc for examples.
|
@@ -116,7 +115,7 @@ require 'yaml'
|
|
116
115
|
#
|
117
116
|
|
118
117
|
class Hoe
|
119
|
-
VERSION = '1.5.
|
118
|
+
VERSION = '1.5.2'
|
120
119
|
|
121
120
|
ruby_prefix = Config::CONFIG['prefix']
|
122
121
|
sitelibdir = Config::CONFIG['sitelibdir']
|
@@ -214,6 +213,11 @@ class Hoe
|
|
214
213
|
|
215
214
|
attr_accessor :lib_files # :nodoc:
|
216
215
|
|
216
|
+
##
|
217
|
+
# Optional: Array of incompatible versions for multiruby filtering. Used as a regex.
|
218
|
+
|
219
|
+
attr_accessor :multiruby_skip
|
220
|
+
|
217
221
|
##
|
218
222
|
# *MANDATORY*: The name of the release.
|
219
223
|
|
@@ -229,6 +233,11 @@ class Hoe
|
|
229
233
|
|
230
234
|
attr_accessor :need_zip
|
231
235
|
|
236
|
+
##
|
237
|
+
# Optional: A post-install message to be displayed when gem is installed.
|
238
|
+
|
239
|
+
attr_accessor :post_install_message
|
240
|
+
|
232
241
|
##
|
233
242
|
# Optional: A regexp to match documentation files against the manifest.
|
234
243
|
|
@@ -300,6 +309,7 @@ class Hoe
|
|
300
309
|
self.description_sections = %w(description)
|
301
310
|
self.email = []
|
302
311
|
self.extra_deps = []
|
312
|
+
self.multiruby_skip = []
|
303
313
|
self.need_tar = true
|
304
314
|
self.need_zip = false
|
305
315
|
self.rdoc_pattern = /^(lib|bin|ext)|txt$/
|
@@ -309,12 +319,18 @@ class Hoe
|
|
309
319
|
self.spec_extras = {}
|
310
320
|
self.summary_sentences = 1
|
311
321
|
self.test_globs = ['test/**/test_*.rb']
|
322
|
+
self.post_install_message = nil
|
312
323
|
|
313
324
|
yield self if block_given?
|
314
325
|
|
315
326
|
# Intuit values:
|
316
327
|
|
317
|
-
|
328
|
+
def missing name
|
329
|
+
warn "** #{name} is missing or in the wrong format for auto-intuiting."
|
330
|
+
warn " run `sow blah` and look at its text files"
|
331
|
+
end
|
332
|
+
|
333
|
+
readme = File.read("README.txt").split(/^(=+ .*)$/)[1..-1] rescue ''
|
318
334
|
unless readme.empty? then
|
319
335
|
sections = readme.map { |s|
|
320
336
|
s =~ /^=/ ? s.strip.downcase.chomp(':').split.last : s.strip
|
@@ -324,14 +340,20 @@ class Hoe
|
|
324
340
|
summ = desc.split(/\.\s+/).first(summary_sentences).join(". ")
|
325
341
|
|
326
342
|
self.description ||= desc
|
327
|
-
self.changes ||= File.read("History.txt").split(/^(===.*)/)[1..2].join.strip
|
328
343
|
self.summary ||= summ
|
329
344
|
self.url ||= readme[1].gsub(/^\* /, '').split(/\n/).grep(/\S+/)
|
330
345
|
else
|
331
|
-
|
332
|
-
warn " run sow blah and look at it's text files"
|
346
|
+
missing 'README.txt'
|
333
347
|
end
|
334
348
|
|
349
|
+
self.changes ||= begin
|
350
|
+
h = File.read("History.txt")
|
351
|
+
h.split(/^(===.*)/)[1..2].join.strip
|
352
|
+
rescue
|
353
|
+
missing 'History.txt'
|
354
|
+
''
|
355
|
+
end
|
356
|
+
|
335
357
|
%w(email author).each do |field|
|
336
358
|
value = self.send(field)
|
337
359
|
if value.nil? or value.empty? then
|
@@ -339,7 +361,7 @@ class Hoe
|
|
339
361
|
warn "Hoe #{field} value not set - Fix by 2008-04-01!"
|
340
362
|
self.send "#{field}=", "doofus"
|
341
363
|
else
|
342
|
-
abort "Hoe #{field} value not set"
|
364
|
+
abort "Hoe #{field} value not set. aborting"
|
343
365
|
end
|
344
366
|
end
|
345
367
|
end
|
@@ -445,6 +467,8 @@ class Hoe
|
|
445
467
|
s.extra_rdoc_files = s.files.grep(/txt$/)
|
446
468
|
s.has_rdoc = true
|
447
469
|
|
470
|
+
s.post_install_message = post_install_message
|
471
|
+
|
448
472
|
if test ?f, "test/test_all.rb" then
|
449
473
|
s.test_file = "test/test_all.rb"
|
450
474
|
else
|
@@ -461,13 +485,11 @@ class Hoe
|
|
461
485
|
if ENV['INLINE'] then
|
462
486
|
s.platform = ENV['FORCE_PLATFORM'] || Gem::Platform::CURRENT
|
463
487
|
# name of the extension is CamelCase
|
464
|
-
if name =~ /[A-Z]/
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
alternate_name = name.strip.split(/\s*_+\s*/).map! { |w| w.downcase.sub(/^./) { |c| c.upcase } }.join
|
470
|
-
end
|
488
|
+
alternate_name = if name =~ /[A-Z]/ then
|
489
|
+
name.gsub(/([A-Z])/, '_\1').downcase.sub(/^_/, '')
|
490
|
+
elsif name =~ /_/ then
|
491
|
+
name.capitalize.gsub(/_([a-z])/) { $1.upcase }
|
492
|
+
end
|
471
493
|
|
472
494
|
# Try collecting Inline extensions for +name+
|
473
495
|
if defined?(Inline) then
|
@@ -599,7 +621,7 @@ class Hoe
|
|
599
621
|
task :clean => [ :clobber_docs, :clobber_package ] do
|
600
622
|
clean_globs.each do |pattern|
|
601
623
|
files = Dir[pattern]
|
602
|
-
rm_rf files unless files.empty?
|
624
|
+
rm_rf files, :verbose => true unless files.empty?
|
603
625
|
end
|
604
626
|
end
|
605
627
|
|
@@ -693,7 +715,8 @@ class Hoe
|
|
693
715
|
require 'find'
|
694
716
|
files = []
|
695
717
|
with_config do |config, _|
|
696
|
-
exclusions = config["exclude"]
|
718
|
+
exclusions = config["exclude"]
|
719
|
+
abort "exclude entry missing from .hoerc. Aborting." if exclusions.nil?
|
697
720
|
Find.find '.' do |path|
|
698
721
|
next unless File.file? path
|
699
722
|
next if path =~ exclusions
|
@@ -778,7 +801,11 @@ class Hoe
|
|
778
801
|
tests.map! {|f| %Q(require "#{f}")}
|
779
802
|
"#{RUBY_FLAGS} -e '#{tests.join("; ")}' #{FILTER}"
|
780
803
|
end
|
804
|
+
|
805
|
+
excludes = multiruby_skip.join(":")
|
806
|
+
ENV['EXCLUDED_VERSIONS'] = excludes
|
781
807
|
cmd = "multiruby #{cmd}" if multi
|
808
|
+
|
782
809
|
send msg, cmd
|
783
810
|
end
|
784
811
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hoe
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryan Davis
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-
|
12
|
+
date: 2008-05-20 00:00:00 -07:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -19,7 +19,7 @@ dependencies:
|
|
19
19
|
requirements:
|
20
20
|
- - ">="
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 0.4.
|
22
|
+
version: 0.4.5
|
23
23
|
version:
|
24
24
|
- !ruby/object:Gem::Dependency
|
25
25
|
name: rake
|
@@ -72,7 +72,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
72
72
|
requirements: []
|
73
73
|
|
74
74
|
rubyforge_project: seattlerb
|
75
|
-
rubygems_version: 1.
|
75
|
+
rubygems_version: 1.1.1
|
76
76
|
signing_key:
|
77
77
|
specification_version: 2
|
78
78
|
summary: Hoe is a simple rake/rubygems helper for project Rakefiles
|