hoe 4.5.2.beta.3 → 4.5.2.beta.5
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.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/README.rdoc +2 -2
- data/lib/hoe.rb +29 -21
- data/test/test_hoe.rb +24 -28
- data.tar.gz.sig +0 -0
- metadata +11 -4
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 332ec6e317de6d96320adac85b6f7c7997a6ea1687b8457ab7242d29f31f153c
|
|
4
|
+
data.tar.gz: acd810ce8688c8edceceaabe1e318bbe6e748434631e7e743d1f4a079bfe727f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 3550d9a52bba302dca25b51586f42699603497a9cdab675668aa161867196217660eb16882d3553162e935623c945c3cd858218d237606f69202f52a9abc6a5a
|
|
7
|
+
data.tar.gz: 145ad07b94d7539ba345fdf1b70aa35963248cad0d7a6c0e34c4664d0373e80b74305077d057acf3c36f1d25cb6c03f864923c76cd066f4fee852e670750d7b5
|
checksums.yaml.gz.sig
CHANGED
|
Binary file
|
data/README.rdoc
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
home :: https://zenspider.com/projects/hoe.html
|
|
4
4
|
code :: https://github.com/seattlerb/hoe
|
|
5
5
|
bugs :: https://github.com/seattlerb/hoe/issues
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
doco :: https://docs.seattlerb.org/hoe/
|
|
7
|
+
doco2 :: https://docs.seattlerb.org/hoe/Hoe.pdf
|
|
8
8
|
clog :: https://github.com/seattlerb/hoe/blob/master/History.rdoc
|
|
9
9
|
other :: https://github.com/jbarnette/hoe-plugin-examples
|
|
10
10
|
|
data/lib/hoe.rb
CHANGED
|
@@ -87,7 +87,7 @@ class Hoe
|
|
|
87
87
|
include Rake::DSL if defined?(Rake::DSL)
|
|
88
88
|
|
|
89
89
|
# duh
|
|
90
|
-
VERSION = "4.5.2.beta.
|
|
90
|
+
VERSION = "4.5.2.beta.5"
|
|
91
91
|
|
|
92
92
|
@@plugins = [:clean, :debug, :deps, :flay, :flog, :newb, :package,
|
|
93
93
|
:publish, :gemcutter, :signing, :test]
|
|
@@ -114,12 +114,20 @@ class Hoe
|
|
|
114
114
|
URLS_TO_META_MAP = {
|
|
115
115
|
"bugs" => "bug_tracker_uri",
|
|
116
116
|
"clog" => "changelog_uri",
|
|
117
|
+
"code" => "source_code_uri",
|
|
117
118
|
"doco" => "documentation_uri",
|
|
118
119
|
"docs" => "documentation_uri",
|
|
119
120
|
"home" => "homepage_uri",
|
|
120
|
-
"code" => "source_code_uri",
|
|
121
|
-
"wiki" => "wiki_uri",
|
|
122
121
|
"mail" => "mailing_list_uri",
|
|
122
|
+
"wiki" => "wiki_uri",
|
|
123
|
+
|
|
124
|
+
"changelog" => "changelog_uri",
|
|
125
|
+
"changes" => "changelog_uri",
|
|
126
|
+
"documentation" => "documentation_uri",
|
|
127
|
+
"history" => "changelog_uri",
|
|
128
|
+
"issues" => "bug_tracker_uri",
|
|
129
|
+
"rdoc" => "documentation_uri",
|
|
130
|
+
"tickets" => "bug_tracker_uri",
|
|
123
131
|
}
|
|
124
132
|
|
|
125
133
|
##
|
|
@@ -651,7 +659,7 @@ class Hoe
|
|
|
651
659
|
self.author = []
|
|
652
660
|
self.changes = nil
|
|
653
661
|
self.description = nil
|
|
654
|
-
self.description_sections = %w[description]
|
|
662
|
+
self.description_sections = %w[description features/problems]
|
|
655
663
|
self.description_rdoc_hack = true
|
|
656
664
|
self.email = []
|
|
657
665
|
self.extra_deps = []
|
|
@@ -692,22 +700,24 @@ class Hoe
|
|
|
692
700
|
.chunk { |l| l[/^(?:=+|#+)/] || "" }
|
|
693
701
|
.map(&:last)
|
|
694
702
|
.each_slice(2)
|
|
703
|
+
.select { |k, v| k && v }
|
|
695
704
|
.to_h { |k, v|
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
}.join("\n")
|
|
705
|
+
kp = k.join.strip.chomp(":").sub(/(?:=+|#+)\s*/, '').downcase
|
|
706
|
+
|
|
707
|
+
# keep key in value, but title case it
|
|
708
|
+
v.prepend k.join.downcase.gsub(/\b[a-z]/, &:upcase)
|
|
701
709
|
|
|
702
710
|
[kp, v.join.strip]
|
|
703
711
|
}
|
|
704
712
|
|
|
705
713
|
unless readme.empty? then
|
|
706
|
-
desc = readme.values_at(*description_sections).join("\n\n")
|
|
707
|
-
desc
|
|
714
|
+
desc = readme.values_at(*description_sections).compact.join("\n\n")
|
|
715
|
+
desc = desc.lines.drop(2).join # drop first header (eg description)
|
|
716
|
+
desc += "\n\n==== To Install:\n" if description_rdoc_hack &&
|
|
717
|
+
desc !~ /^==+ [A-Z]/
|
|
708
718
|
summ = desc.split(/\.\s+/).first(summary_sentences).join(". ")
|
|
709
719
|
|
|
710
|
-
self.urls ||= parse_urls(readme.values.first)
|
|
720
|
+
self.urls ||= parse_urls(readme.values.first.lines.drop(1).join)
|
|
711
721
|
self.description ||= desc
|
|
712
722
|
self.summary ||= summ
|
|
713
723
|
else
|
|
@@ -742,13 +752,10 @@ class Hoe
|
|
|
742
752
|
# should update the readme.
|
|
743
753
|
|
|
744
754
|
def parse_urls text
|
|
745
|
-
|
|
755
|
+
keys = Regexp.union Hoe::URLS_TO_META_MAP.keys
|
|
756
|
+
kv_re = /^\s*(#{keys})\s*::\s*<?([^>\s]+)>?/
|
|
746
757
|
|
|
747
|
-
|
|
748
|
-
Hash[lines.map { |line| line.split(/\s*::\s*/) }]
|
|
749
|
-
else
|
|
750
|
-
raise "Please switch readme to hash format for urls."
|
|
751
|
-
end
|
|
758
|
+
text.scan(kv_re).to_h
|
|
752
759
|
end
|
|
753
760
|
|
|
754
761
|
##
|
|
@@ -781,11 +788,12 @@ class Hoe
|
|
|
781
788
|
end
|
|
782
789
|
|
|
783
790
|
##
|
|
784
|
-
#
|
|
791
|
+
# Raise about a file that is missing data or unparsable for intuiting values.
|
|
785
792
|
|
|
786
793
|
def missing name
|
|
787
|
-
|
|
788
|
-
|
|
794
|
+
raise \
|
|
795
|
+
"** #{name} is missing or in the wrong format for auto-intuiting." \
|
|
796
|
+
" run `sow blah` and look at its text files"
|
|
789
797
|
end
|
|
790
798
|
|
|
791
799
|
##
|
data/test/test_hoe.rb
CHANGED
|
@@ -8,9 +8,16 @@ class Hoe
|
|
|
8
8
|
end
|
|
9
9
|
end
|
|
10
10
|
|
|
11
|
-
$rakefile = nil # shuts up a warning in rdoctask.rb
|
|
12
|
-
|
|
13
11
|
class TestHoe < Minitest::Test
|
|
12
|
+
def without_plugins
|
|
13
|
+
old = Hoe.plugins.dup
|
|
14
|
+
Hoe.plugins.clear
|
|
15
|
+
|
|
16
|
+
yield
|
|
17
|
+
ensure
|
|
18
|
+
Hoe.plugins.replace old
|
|
19
|
+
end
|
|
20
|
+
|
|
14
21
|
def hoe *skips, &b
|
|
15
22
|
@hoe ||= Hoe.spec "blah" do
|
|
16
23
|
developer "author", "email"
|
|
@@ -150,6 +157,8 @@ class TestHoe < Minitest::Test
|
|
|
150
157
|
File.write "README.rdoc", "= blah\n\nhome :: http://blah/"
|
|
151
158
|
File.write "History.rdoc", "=== 1.0"
|
|
152
159
|
|
|
160
|
+
hoe = without_plugins { self.hoe }
|
|
161
|
+
|
|
153
162
|
assert_equal "History.rdoc", hoe.history_file
|
|
154
163
|
assert_equal "README.rdoc", hoe.readme_file
|
|
155
164
|
assert_equal %w[FAQ.rdoc History.rdoc README.rdoc],
|
|
@@ -180,7 +189,7 @@ class TestHoe < Minitest::Test
|
|
|
180
189
|
hoe
|
|
181
190
|
end
|
|
182
191
|
|
|
183
|
-
|
|
192
|
+
assert_match(/wrong format/, e.message)
|
|
184
193
|
end
|
|
185
194
|
end
|
|
186
195
|
end
|
|
@@ -196,30 +205,17 @@ class TestHoe < Minitest::Test
|
|
|
196
205
|
end
|
|
197
206
|
end
|
|
198
207
|
|
|
199
|
-
def test_parse_urls_ary
|
|
200
|
-
ary = ["* https://github.com/seattlerb/hoe",
|
|
201
|
-
"* http://docs.seattlerb.org/hoe/",
|
|
202
|
-
"* http://docs.seattlerb.org/hoe/Hoe.pdf",
|
|
203
|
-
"* http://github.com/jbarnette/hoe-plugin-examples"].join "\n"
|
|
204
|
-
|
|
205
|
-
assert_raises RuntimeError do
|
|
206
|
-
hoe.parse_urls ary
|
|
207
|
-
end
|
|
208
|
-
end
|
|
209
|
-
|
|
210
208
|
def test_parse_urls_hash
|
|
211
209
|
hash = [
|
|
212
210
|
"home :: https://github.com/seattlerb/hoe",
|
|
213
|
-
"rdoc ::
|
|
214
|
-
"
|
|
215
|
-
"other ::
|
|
211
|
+
"rdoc :: https://docs.seattlerb.org/hoe/",
|
|
212
|
+
"doco2 :: https://docs.seattlerb.org/hoe/Hoe.pdf",
|
|
213
|
+
"other :: https://github.com/jbarnette/hoe-plugin-examples",
|
|
216
214
|
].join "\n"
|
|
217
215
|
|
|
218
216
|
exp = {
|
|
219
|
-
"home"
|
|
220
|
-
"rdoc"
|
|
221
|
-
"doco" => "http://docs.seattlerb.org/hoe/Hoe.pdf",
|
|
222
|
-
"other" => "http://github.com/jbarnette/hoe-plugin-examples",
|
|
217
|
+
"home" => "https://github.com/seattlerb/hoe",
|
|
218
|
+
"rdoc" => "https://docs.seattlerb.org/hoe/",
|
|
223
219
|
}
|
|
224
220
|
|
|
225
221
|
assert_equal exp, hoe.parse_urls(hash)
|
|
@@ -242,8 +238,6 @@ class TestHoe < Minitest::Test
|
|
|
242
238
|
make working with file tasks cleaner, easier, and faster.
|
|
243
239
|
EOM
|
|
244
240
|
|
|
245
|
-
|
|
246
|
-
|
|
247
241
|
assert_silent do
|
|
248
242
|
h = Hoe.spec "blah" do
|
|
249
243
|
developer "author", "email"
|
|
@@ -259,7 +253,7 @@ class TestHoe < Minitest::Test
|
|
|
259
253
|
|
|
260
254
|
desc = mrww_readme.lines[10..11].join.chomp
|
|
261
255
|
summ = desc.chomp(".")
|
|
262
|
-
rdoc = "\n\n
|
|
256
|
+
rdoc = "\n\n==== To Install:\n"
|
|
263
257
|
desc += rdoc
|
|
264
258
|
|
|
265
259
|
urls = {
|
|
@@ -356,6 +350,8 @@ class TestHoe < Minitest::Test
|
|
|
356
350
|
assert_equal exp, hoe.parse_urls(hash)
|
|
357
351
|
end
|
|
358
352
|
|
|
353
|
+
make_my_diffs_pretty!
|
|
354
|
+
|
|
359
355
|
def test_possibly_better
|
|
360
356
|
t = Gem::Specification::TODAY
|
|
361
357
|
|
|
@@ -372,10 +368,8 @@ class TestHoe < Minitest::Test
|
|
|
372
368
|
"home" => "https://zenspider.com/projects/hoe.html",
|
|
373
369
|
"code" => "https://github.com/seattlerb/hoe",
|
|
374
370
|
"bugs" => "https://github.com/seattlerb/hoe/issues",
|
|
375
|
-
"
|
|
376
|
-
"doco" => "https://docs.seattlerb.org/hoe/Hoe.pdf",
|
|
371
|
+
"doco" => "https://docs.seattlerb.org/hoe/",
|
|
377
372
|
"clog" => "https://github.com/seattlerb/hoe/blob/master/History.rdoc",
|
|
378
|
-
"other" => "https://github.com/jbarnette/hoe-plugin-examples",
|
|
379
373
|
}
|
|
380
374
|
|
|
381
375
|
assert_equal urls, hoe.urls
|
|
@@ -401,8 +395,10 @@ class TestHoe < Minitest::Test
|
|
|
401
395
|
|
|
402
396
|
deps = spec.dependencies.sort_by(&:name)
|
|
403
397
|
|
|
398
|
+
version = Hoe::VERSION[/\d+\.\d+/]
|
|
399
|
+
|
|
404
400
|
expected = [
|
|
405
|
-
["hoe", :development, "~> #{
|
|
401
|
+
["hoe", :development, "~> #{version}"],
|
|
406
402
|
["rdoc", :development, "< 8", ">= 6.0"],
|
|
407
403
|
]
|
|
408
404
|
|
data.tar.gz.sig
CHANGED
|
Binary file
|
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: 4.5.2.beta.
|
|
4
|
+
version: 4.5.2.beta.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ryan Davis
|
|
@@ -78,7 +78,7 @@ dependencies:
|
|
|
78
78
|
- - "~>"
|
|
79
79
|
- !ruby/object:Gem::Version
|
|
80
80
|
version: '0.21'
|
|
81
|
-
description:
|
|
81
|
+
description: |-
|
|
82
82
|
Hoe is a rake/rubygems helper for project Rakefiles. It helps you
|
|
83
83
|
manage, maintain, and release your project and includes a dynamic
|
|
84
84
|
plug-in system allowing for easy extensibility. Hoe ships with
|
|
@@ -90,7 +90,14 @@ description: |
|
|
|
90
90
|
|
|
91
91
|
For extra goodness, see: https://docs.seattlerb.org/hoe/Hoe.pdf
|
|
92
92
|
|
|
93
|
-
|
|
93
|
+
== Features/Problems:
|
|
94
|
+
|
|
95
|
+
* Includes a dynamic plug-in system allowing for easy extensibility.
|
|
96
|
+
* Auto-intuits changes, description, summary, and version.
|
|
97
|
+
* Uses a manifest for safe and secure deployment.
|
|
98
|
+
* Provides 'sow' for quick project directory creation.
|
|
99
|
+
* Sow uses a simple ERB templating system allowing you to capture your
|
|
100
|
+
project patterns.
|
|
94
101
|
email:
|
|
95
102
|
- ryand-ruby@zenspider.com
|
|
96
103
|
executables:
|
|
@@ -149,7 +156,7 @@ metadata:
|
|
|
149
156
|
homepage_uri: https://zenspider.com/projects/hoe.html
|
|
150
157
|
source_code_uri: https://github.com/seattlerb/hoe
|
|
151
158
|
bug_tracker_uri: https://github.com/seattlerb/hoe/issues
|
|
152
|
-
documentation_uri: https://docs.seattlerb.org/hoe/
|
|
159
|
+
documentation_uri: https://docs.seattlerb.org/hoe/
|
|
153
160
|
changelog_uri: https://github.com/seattlerb/hoe/blob/master/History.rdoc
|
|
154
161
|
rdoc_options:
|
|
155
162
|
- "--main"
|
metadata.gz.sig
CHANGED
|
Binary file
|