echoe 4.3.1 → 4.4
Sign up to get free protection for your applications and to get access to all the features.
- data.tar.gz.sig +0 -0
- data/CHANGELOG +3 -1
- data/Rakefile +0 -2
- data/echoe.gemspec +5 -5
- data/lib/echoe.rb +53 -40
- metadata +14 -6
- metadata.gz.sig +0 -0
data.tar.gz.sig
CHANGED
Binary file
|
data/CHANGELOG
CHANGED
@@ -1,4 +1,6 @@
|
|
1
|
-
v4.
|
1
|
+
v4.4. Use GitHub for default url and documentation hosting.
|
2
|
+
|
3
|
+
v4.3.1. Don't stop if gemcutter's plugin cannot be loaded, don't define RSpec tasks if RSpec is not present (Flameeyes). Use Dir.tmpdir.
|
2
4
|
|
3
5
|
v4.3. Don't use sudo if the GEM_HOME is local. Support prerelease gem versions.
|
4
6
|
|
data/Rakefile
CHANGED
@@ -5,8 +5,6 @@ Echoe.new('echoe') do |p|
|
|
5
5
|
p.project = 'fauna'
|
6
6
|
p.author = 'Evan Weaver'
|
7
7
|
p.summary = 'A Rubygems packaging tool that provides Rake tasks for documentation, extension compiling, testing, and deployment.'
|
8
|
-
p.url = 'http://blog.evanweaver.com/files/doc/fauna/echoe/'
|
9
|
-
p.docs_host = 'blog.evanweaver.com:~/www/bax/public/files/doc/'
|
10
8
|
p.runtime_dependencies = ['gemcutter', 'rubyforge']
|
11
9
|
p.development_dependencies = []
|
12
10
|
p.retain_gemspec = true
|
data/echoe.gemspec
CHANGED
@@ -2,21 +2,21 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{echoe}
|
5
|
-
s.version = "4.
|
5
|
+
s.version = "4.4"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Evan Weaver"]
|
9
9
|
s.cert_chain = ["/Users/eweaver/p/configuration/gem_certificates/evan_weaver-original-public_cert.pem"]
|
10
|
-
s.date = %q{
|
10
|
+
s.date = %q{2011-02-22}
|
11
11
|
s.description = %q{A Rubygems packaging tool that provides Rake tasks for documentation, extension compiling, testing, and deployment.}
|
12
12
|
s.email = %q{}
|
13
13
|
s.extra_rdoc_files = ["CHANGELOG", "LICENSE", "README", "TODO", "lib/echoe.rb", "lib/echoe/extensions.rb", "lib/echoe/platform.rb", "lib/echoe/rubygems.rb"]
|
14
14
|
s.files = ["CHANGELOG", "LICENSE", "MIT-LICENSE", "Manifest", "README", "Rakefile", "TODO", "echoe.gemspec", "lib/echoe.rb", "lib/echoe/extensions.rb", "lib/echoe/platform.rb", "lib/echoe/rubygems.rb", "vendor/rake/MIT-LICENSE", "vendor/rake/lib/rake/contrib/compositepublisher.rb", "vendor/rake/lib/rake/contrib/ftptools.rb", "vendor/rake/lib/rake/contrib/publisher.rb", "vendor/rake/lib/rake/contrib/rubyforgepublisher.rb", "vendor/rake/lib/rake/contrib/sshpublisher.rb", "vendor/rake/lib/rake/contrib/sys.rb"]
|
15
|
-
s.homepage = %q{http://
|
15
|
+
s.homepage = %q{http://fauna.github.com/echoe/}
|
16
16
|
s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Echoe", "--main", "README"]
|
17
17
|
s.require_paths = ["lib"]
|
18
18
|
s.rubyforge_project = %q{fauna}
|
19
|
-
s.rubygems_version = %q{1.3.
|
19
|
+
s.rubygems_version = %q{1.3.7}
|
20
20
|
s.signing_key = %q{/Users/eweaver/p/configuration/gem_certificates/evan_weaver-original-private_key.pem}
|
21
21
|
s.summary = %q{A Rubygems packaging tool that provides Rake tasks for documentation, extension compiling, testing, and deployment.}
|
22
22
|
|
@@ -24,7 +24,7 @@ Gem::Specification.new do |s|
|
|
24
24
|
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
25
25
|
s.specification_version = 3
|
26
26
|
|
27
|
-
if Gem::Version.new(Gem::
|
27
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
28
28
|
s.add_runtime_dependency(%q<gemcutter>, [">= 0"])
|
29
29
|
s.add_runtime_dependency(%q<rubyforge>, [">= 0"])
|
30
30
|
else
|
data/lib/echoe.rb
CHANGED
@@ -14,6 +14,7 @@ rescue LoadError
|
|
14
14
|
end
|
15
15
|
require 'rbconfig'
|
16
16
|
require 'open-uri'
|
17
|
+
require 'tmpdir'
|
17
18
|
|
18
19
|
require "#{$HERE}/echoe/extensions"
|
19
20
|
|
@@ -43,8 +44,6 @@ For example, a simple <tt>Rakefile</tt> might look like this:
|
|
43
44
|
Echoe.new("uncapitalizer") do |p|
|
44
45
|
p.author = "Evan Weaver"
|
45
46
|
p.summary = "A library that uncapitalizes strings."
|
46
|
-
p.url = "http://www.uncapitalizer.com"
|
47
|
-
p.docs_host = "uncapitalizer.com:~/www/files/doc/"
|
48
47
|
p.runtime_dependencies = ["string_tools >=1.4.0"]
|
49
48
|
end
|
50
49
|
|
@@ -96,7 +95,7 @@ Descriptive options:
|
|
96
95
|
* <tt>email</tt> - Your email address.
|
97
96
|
* <tt>description</tt> - A more detailed description of the library.
|
98
97
|
* <tt>summary</tt> - A shorter description of the library.
|
99
|
-
* <tt>url</tt> - A url for the library.
|
98
|
+
* <tt>url</tt> - A url for the library. Defaults to generated RDoc on GitHub pages for the project.f
|
100
99
|
* <tt>install_message</tt> - A message to display after the gem is installed.
|
101
100
|
|
102
101
|
Versioning options:
|
@@ -142,7 +141,7 @@ Security options:
|
|
142
141
|
Publishing options:
|
143
142
|
|
144
143
|
* <tt>project</tt> - The name of the Rubyforge project. Defaults to the name of the gem.
|
145
|
-
* <tt>docs_host</tt> - A host and filesystem path to publish the documentation to. Defaults to the
|
144
|
+
* <tt>docs_host</tt> - A host and filesystem path to publish the documentation to. Defaults to GitHub pages for the project. SSH upload to an accessible static file host also works.
|
146
145
|
|
147
146
|
Documentation options:
|
148
147
|
|
@@ -168,15 +167,14 @@ class Echoe
|
|
168
167
|
self.name = name
|
169
168
|
self.project = name.downcase
|
170
169
|
self.changelog = "CHANGELOG"
|
171
|
-
self.url = ""
|
172
170
|
self.author = ""
|
173
171
|
self.email = ""
|
174
172
|
self.clean_pattern = ["pkg", "doc", 'build/*', '**/coverage', '**/*.o', '**/*.so', '**/*.a', '**/*.log', "{ext,lib}/*.{bundle,so,obj,pdb,lib,def,exp}", "ext/Makefile", "{ext,lib}/**/*.{bundle,so,obj,pdb,lib,def,exp}", "ext/**/Makefile", "pkg", "*.gem", ".config"]
|
175
173
|
self.test_pattern = File.exist?("test/test_all.rb") ? "test/test_all.rb" : ['test/**/test_*.rb', 'test/**/*_test.rb']
|
176
174
|
self.spec_pattern = "spec/**/*_spec.rb"
|
177
|
-
|
175
|
+
|
178
176
|
self.ignore_pattern = /^(pkg|doc)|\.svn|CVS|\.bzr|\.DS|\.git/
|
179
|
-
|
177
|
+
|
180
178
|
self.changelog_patterns = {
|
181
179
|
:version => [
|
182
180
|
/^\s*v([\d\w\.]+)(\.|\s|$)/,
|
@@ -230,6 +228,11 @@ class Echoe
|
|
230
228
|
|
231
229
|
yield self if block_given?
|
232
230
|
|
231
|
+
self.docs_host ||= "git@github.com:#{self.project}/#{self.project}.github.com"
|
232
|
+
if self.docs_host =~ /git@github.com/
|
233
|
+
self.url ||= "http://#{self.project}.github.com/#{(self.name + '/') if project != name}"
|
234
|
+
end
|
235
|
+
|
233
236
|
# legacy compatibility
|
234
237
|
self.runtime_dependencies = dependencies if dependencies and runtime_dependencies.empty?
|
235
238
|
self.runtime_dependencies = extra_deps if extra_deps and runtime_dependencies.empty?
|
@@ -287,10 +290,10 @@ class Echoe
|
|
287
290
|
self.summary = description if summary.empty?
|
288
291
|
self.clean_pattern = apply_pattern(clean_pattern)
|
289
292
|
self.extension_pattern = apply_pattern(extension_pattern, files)
|
290
|
-
|
293
|
+
|
291
294
|
self.ignore_pattern = apply_pattern(ignore_pattern)
|
292
295
|
honor_gitignore! if File.exist?(".git")
|
293
|
-
|
296
|
+
|
294
297
|
self.rdoc_pattern = apply_pattern(rdoc_pattern, files) - [manifest_name]
|
295
298
|
self.executable_pattern = apply_pattern(executable_pattern, files)
|
296
299
|
self.test_pattern = apply_pattern(test_pattern)
|
@@ -298,22 +301,22 @@ class Echoe
|
|
298
301
|
|
299
302
|
define_tasks
|
300
303
|
end
|
301
|
-
|
304
|
+
|
302
305
|
private
|
303
306
|
def honor_gitignore!
|
304
307
|
self.ignore_pattern += \
|
305
|
-
Dir["**/.gitignore"].inject([]) do |pattern,gitignore|
|
308
|
+
Dir["**/.gitignore"].inject([]) do |pattern,gitignore|
|
306
309
|
pattern.concat \
|
307
310
|
File.readlines(gitignore).
|
308
311
|
map { |line| line.strip }.
|
309
312
|
reject { |line| "" == line }.
|
310
|
-
map { |glob|
|
313
|
+
map { |glob|
|
311
314
|
d = File.dirname(gitignore)
|
312
315
|
d == "." ? glob : File.join(d, glob)
|
313
316
|
}
|
314
317
|
end.flatten.uniq
|
315
318
|
end
|
316
|
-
|
319
|
+
|
317
320
|
def apply_pattern(pattern, files = nil)
|
318
321
|
files ||= Dir['**/**']
|
319
322
|
case pattern
|
@@ -416,25 +419,25 @@ private
|
|
416
419
|
pkg.need_tar_gz = @need_tar_gz
|
417
420
|
pkg.need_zip = @need_zip
|
418
421
|
end
|
419
|
-
|
422
|
+
|
420
423
|
desc "Display Echoe's knowledge of your system"
|
421
424
|
task :details do
|
422
425
|
(self.instance_variables.sort - ['@spec']).each do |var|
|
423
426
|
puts "#{var}: #{instance_variable_get(var).inspect}"
|
424
427
|
end
|
425
428
|
end
|
426
|
-
|
429
|
+
|
427
430
|
desc "Builds the .gemspec"
|
428
431
|
task :build_gemspec do
|
429
432
|
# Construct the gemspec file, if needed.
|
430
433
|
if include_gemspec
|
431
|
-
File.open(gemspec_name, 'w') do |f|
|
434
|
+
File.open(gemspec_name, 'w') do |f|
|
432
435
|
case gemspec_format
|
433
436
|
when :yaml
|
434
437
|
spec.to_yaml.split("\n").each do |line|
|
435
438
|
# Don't publish any information about the private key or certificate chain
|
436
439
|
f.puts line unless line =~ /signing_key|cert_chain|\.pem/
|
437
|
-
end
|
440
|
+
end
|
438
441
|
when :ruby
|
439
442
|
f.puts spec.to_ruby
|
440
443
|
else
|
@@ -497,7 +500,7 @@ private
|
|
497
500
|
pkg_tar = pkg + ".tgz"
|
498
501
|
pkg_tar_gz = pkg + ".tar.gz"
|
499
502
|
pkg_zip = pkg + ".zip"
|
500
|
-
|
503
|
+
|
501
504
|
puts "Releasing #{name} v. #{version} to Gemcutter."
|
502
505
|
system("gem push #{pkg_gem.inspect}")
|
503
506
|
end
|
@@ -559,33 +562,43 @@ private
|
|
559
562
|
|
560
563
|
task :doc => [:redocs]
|
561
564
|
|
562
|
-
desc "Publish documentation to
|
565
|
+
desc "Publish documentation to the internet."
|
563
566
|
task :publish_docs => [:clean, :docs] do
|
564
567
|
|
565
|
-
local_dir = 'doc'
|
566
|
-
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
|
572
|
-
|
573
|
-
|
574
|
-
|
575
|
-
|
576
|
-
|
577
|
-
|
578
|
-
|
579
|
-
|
580
|
-
|
581
|
-
|
568
|
+
local_dir = File.expand_path('doc')
|
569
|
+
|
570
|
+
if docs_host =~ /git@github.com/
|
571
|
+
Dir.mktmpdir do |dir|
|
572
|
+
Dir.chdir(dir) do
|
573
|
+
puts "Working in: #{dir}"
|
574
|
+
cmd = "git clone #{docs_host}"
|
575
|
+
puts "Cloning existing docs: #{cmd}"
|
576
|
+
system(cmd)
|
577
|
+
|
578
|
+
repository_name = docs_host.split("/").last
|
579
|
+
Dir.chdir(repository_name) do
|
580
|
+
project_dir_name = project
|
581
|
+
project_dir_name += "/#{name}" if project != name
|
582
|
+
Dir.mkdir(name) rescue nil
|
583
|
+
|
584
|
+
cmd = "rm -rf '#{project_dir_name}' && mv #{local_dir} '#{project_dir_name}'"
|
585
|
+
puts("Moving docs into checkout: #{cmd}")
|
586
|
+
system(cmd)
|
587
|
+
|
588
|
+
cmd = "git add '#{project_dir_name}' && git commit -a -m 'Update documentation for #{name} #{version}'"
|
589
|
+
puts "Committing changes: #{cmd}"
|
590
|
+
system(cmd)
|
591
|
+
|
592
|
+
cmd = "git push"
|
593
|
+
puts "Pushing changes: #{cmd}"
|
582
594
|
system(cmd)
|
583
595
|
end
|
584
596
|
end
|
585
597
|
end
|
586
|
-
pub.upload
|
587
598
|
else
|
588
599
|
# you may need ssh keys configured for this to work
|
600
|
+
remote_dir_name = project
|
601
|
+
remote_dir_name += "/#{name}" if project != name
|
589
602
|
host, dir = docs_host.split(":")
|
590
603
|
dir.chomp!("/")
|
591
604
|
|
@@ -605,11 +618,11 @@ private
|
|
605
618
|
|
606
619
|
filename = "#{Dir.tmpdir}/#{name}_#{version}_announcement.txt"
|
607
620
|
|
608
|
-
if File.exist?(filename)
|
609
|
-
puts "Announcement file already exists. Please delete #{filename.inspect} first."
|
621
|
+
if File.exist?(filename)
|
622
|
+
puts "Announcement file already exists. Please delete #{filename.inspect} first."
|
610
623
|
exit(1)
|
611
624
|
end
|
612
|
-
|
625
|
+
|
613
626
|
File.open(filename, 'w') do |f|
|
614
627
|
f.write "Subject: #{name.capitalize} #{version}\n\n"
|
615
628
|
f.write "#{name.capitalize} has been updated to #{version}. #{name.capitalize} is #{summary.uncapitalize}\n\n"
|
metadata
CHANGED
@@ -1,12 +1,12 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: echoe
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
+
hash: 19
|
4
5
|
prerelease: false
|
5
6
|
segments:
|
6
7
|
- 4
|
7
|
-
-
|
8
|
-
|
9
|
-
version: 4.3.1
|
8
|
+
- 4
|
9
|
+
version: "4.4"
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Evan Weaver
|
@@ -35,16 +35,18 @@ cert_chain:
|
|
35
35
|
yZ0=
|
36
36
|
-----END CERTIFICATE-----
|
37
37
|
|
38
|
-
date:
|
38
|
+
date: 2011-02-22 00:00:00 -08:00
|
39
39
|
default_executable:
|
40
40
|
dependencies:
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: gemcutter
|
43
43
|
prerelease: false
|
44
44
|
requirement: &id001 !ruby/object:Gem::Requirement
|
45
|
+
none: false
|
45
46
|
requirements:
|
46
47
|
- - ">="
|
47
48
|
- !ruby/object:Gem::Version
|
49
|
+
hash: 3
|
48
50
|
segments:
|
49
51
|
- 0
|
50
52
|
version: "0"
|
@@ -54,9 +56,11 @@ dependencies:
|
|
54
56
|
name: rubyforge
|
55
57
|
prerelease: false
|
56
58
|
requirement: &id002 !ruby/object:Gem::Requirement
|
59
|
+
none: false
|
57
60
|
requirements:
|
58
61
|
- - ">="
|
59
62
|
- !ruby/object:Gem::Version
|
63
|
+
hash: 3
|
60
64
|
segments:
|
61
65
|
- 0
|
62
66
|
version: "0"
|
@@ -98,7 +102,7 @@ files:
|
|
98
102
|
- vendor/rake/lib/rake/contrib/sshpublisher.rb
|
99
103
|
- vendor/rake/lib/rake/contrib/sys.rb
|
100
104
|
has_rdoc: true
|
101
|
-
homepage: http://
|
105
|
+
homepage: http://fauna.github.com/echoe/
|
102
106
|
licenses: []
|
103
107
|
|
104
108
|
post_install_message:
|
@@ -112,16 +116,20 @@ rdoc_options:
|
|
112
116
|
require_paths:
|
113
117
|
- lib
|
114
118
|
required_ruby_version: !ruby/object:Gem::Requirement
|
119
|
+
none: false
|
115
120
|
requirements:
|
116
121
|
- - ">="
|
117
122
|
- !ruby/object:Gem::Version
|
123
|
+
hash: 3
|
118
124
|
segments:
|
119
125
|
- 0
|
120
126
|
version: "0"
|
121
127
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
128
|
+
none: false
|
122
129
|
requirements:
|
123
130
|
- - ">="
|
124
131
|
- !ruby/object:Gem::Version
|
132
|
+
hash: 11
|
125
133
|
segments:
|
126
134
|
- 1
|
127
135
|
- 2
|
@@ -129,7 +137,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
129
137
|
requirements: []
|
130
138
|
|
131
139
|
rubyforge_project: fauna
|
132
|
-
rubygems_version: 1.3.
|
140
|
+
rubygems_version: 1.3.7
|
133
141
|
signing_key:
|
134
142
|
specification_version: 3
|
135
143
|
summary: A Rubygems packaging tool that provides Rake tasks for documentation, extension compiling, testing, and deployment.
|
metadata.gz.sig
CHANGED
Binary file
|