jeffrafter-gemstalker 0.2.1 → 0.3.3
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +18 -0
- data/Rakefile +16 -17
- data/VERSION.yml +2 -2
- data/bin/gemstalk +70 -0
- data/lib/{gemstalker.rb → gem_stalker.rb} +18 -0
- data/test/responses/bostonrb-tree-master +565 -0
- data/test/responses/bostonrb.gemspec +13 -0
- data/test/responses/jeweler-tree-master +728 -0
- data/test/responses/jeweler.gemspec +48 -0
- data/test/responses/specs.4.8.gz +0 -0
- data/test/responses/technicalpickles-jeweler-0.8.1.gem +0 -0
- data/test/responses/technicalpickles-jeweler-0.9.3.gem +15 -0
- data/test/test_helper.rb +26 -1
- metadata +16 -8
- data/README +0 -24
- data/bin/stalk +0 -68
@@ -0,0 +1,48 @@
|
|
1
|
+
HTTP/1.1 200 OK
|
2
|
+
Server: nginx/0.6.31
|
3
|
+
Date: Fri, 13 Feb 2009 20:36:19 GMT
|
4
|
+
Content-Type: text/plain; charset=utf-8
|
5
|
+
Connection: keep-alive
|
6
|
+
Set-Cookie: _github_ses=BAh7BiIKZmxhc2hJQzonQWN0aW9uQ29udHJvbGxlcjo6Rmxhc2g6OkZsYXNoSGFzaHsABjoKQHVzZWR7AA%3D%3D--884981fc5aa85daf318eeff084d98e2cff92578f; path=/; expires=Wed, 01 Jan 2020 08:00:00 GMT; HttpOnly
|
7
|
+
Status: 200 OK
|
8
|
+
X-Runtime: 390ms
|
9
|
+
ETag: "5fb2ee445a74759f606da4ff5258fc0c"
|
10
|
+
Content-Transfer-Encoding: binary
|
11
|
+
Cache-Control: private
|
12
|
+
Content-Disposition: inline
|
13
|
+
Content-Length: 2868
|
14
|
+
|
15
|
+
# -*- encoding: utf-8 -*-
|
16
|
+
|
17
|
+
Gem::Specification.new do |s|
|
18
|
+
s.name = %q{jeweler}
|
19
|
+
s.version = "0.8.1"
|
20
|
+
|
21
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
22
|
+
s.authors = ["Josh Nichols"]
|
23
|
+
s.date = %q{2009-02-03}
|
24
|
+
s.default_executable = %q{jeweler}
|
25
|
+
s.description = %q{Simple and opinionated helper for creating Rubygem projects on GitHub}
|
26
|
+
s.email = %q{josh@technicalpickles.com}
|
27
|
+
s.executables = ["jeweler"]
|
28
|
+
s.files = ["ChangeLog.markdown", "LICENSE", "Rakefile", "README.markdown", "TODO", "VERSION.yml", "bin/jeweler", "lib/jeweler", "lib/jeweler/errors.rb", "lib/jeweler/gemspec.rb", "lib/jeweler/generator.rb", "lib/jeweler/tasks.rb", "lib/jeweler/templates", "lib/jeweler/templates/bacon", "lib/jeweler/templates/bacon/flunking.rb", "lib/jeweler/templates/bacon/helper.rb", "lib/jeweler/templates/features", "lib/jeweler/templates/features/default.feature", "lib/jeweler/templates/features/steps", "lib/jeweler/templates/features/steps/default_steps.rb", "lib/jeweler/templates/features/support", "lib/jeweler/templates/features/support/env.rb", "lib/jeweler/templates/LICENSE", "lib/jeweler/templates/minitest", "lib/jeweler/templates/minitest/flunking.rb", "lib/jeweler/templates/minitest/helper.rb", "lib/jeweler/templates/Rakefile", "lib/jeweler/templates/README", "lib/jeweler/templates/rspec", "lib/jeweler/templates/rspec/flunking.rb", "lib/jeweler/templates/rspec/helper.rb", "lib/jeweler/templates/shoulda", "lib/jeweler/templates/shoulda/flunking.rb", "lib/jeweler/templates/shoulda/helper.rb", "lib/jeweler/templates/testunit", "lib/jeweler/templates/testunit/flunking.rb", "lib/jeweler/templates/testunit/helper.rb", "lib/jeweler/version.rb", "lib/jeweler.rb", "test/fixtures", "test/fixtures/bar", "test/fixtures/bar/VERSION.yml", "test/generators", "test/generators/initialization_test.rb", "test/jeweler", "test/shoulda_macros", "test/shoulda_macros/jeweler_macros.rb", "test/test_gemspec.rb", "test/test_helper.rb", "test/test_jeweler.rb", "test/test_tasks.rb", "test/test_version.rb", "test/version_tmp", "test/version_tmp/VERSION.yml", "lib/jeweler/templates/.gitignore"]
|
29
|
+
s.has_rdoc = true
|
30
|
+
s.homepage = %q{http://github.com/technicalpickles/jeweler}
|
31
|
+
s.rdoc_options = ["--inline-source", "--charset=UTF-8"]
|
32
|
+
s.require_paths = ["lib"]
|
33
|
+
s.rubygems_version = %q{1.3.1}
|
34
|
+
s.summary = %q{Simple and opinionated helper for creating Rubygem projects on GitHub}
|
35
|
+
|
36
|
+
if s.respond_to? :specification_version then
|
37
|
+
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
38
|
+
s.specification_version = 2
|
39
|
+
|
40
|
+
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
|
41
|
+
s.add_runtime_dependency(%q<schacon-git>, [">= 0"])
|
42
|
+
else
|
43
|
+
s.add_dependency(%q<schacon-git>, [">= 0"])
|
44
|
+
end
|
45
|
+
else
|
46
|
+
s.add_dependency(%q<schacon-git>, [">= 0"])
|
47
|
+
end
|
48
|
+
end
|
Binary file
|
Binary file
|
@@ -0,0 +1,15 @@
|
|
1
|
+
HTTP/1.1 404 Not Found
|
2
|
+
Server: nginx/0.6.26
|
3
|
+
Date: Fri, 13 Feb 2009 20:37:35 GMT
|
4
|
+
Content-Type: text/html
|
5
|
+
Content-Length: 169
|
6
|
+
Connection: keep-alive
|
7
|
+
Keep-Alive: timeout=20
|
8
|
+
|
9
|
+
<html>
|
10
|
+
<head><title>404 Not Found</title></head>
|
11
|
+
<body bgcolor="white">
|
12
|
+
<center><h1>404 Not Found</h1></center>
|
13
|
+
<hr><center>nginx/0.6.26</center>
|
14
|
+
</body>
|
15
|
+
</html>
|
data/test/test_helper.rb
CHANGED
@@ -2,9 +2,34 @@ require 'rubygems'
|
|
2
2
|
require 'test/unit'
|
3
3
|
require 'shoulda'
|
4
4
|
require 'ruby-debug'
|
5
|
+
require 'fake_web'
|
5
6
|
|
6
7
|
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
7
|
-
|
8
|
+
$LOAD_PATH.unshift(File.dirname(__FILE__), '..', 'lib')
|
9
|
+
require 'gem_stalker'
|
10
|
+
|
11
|
+
FakeWeb.allow_net_connect = false
|
12
|
+
FakeWeb.register_uri 'http://gems.github.com:80/gems/technicalpickles-jeweler-0.8.1.gem',
|
13
|
+
:response => File.join(File.dirname(__FILE__), 'responses', 'technicalpickles-jeweler-0.8.1.gem')
|
14
|
+
|
15
|
+
FakeWeb.register_uri 'http://gems.github.com:80/specs.4.8.gz',
|
16
|
+
:response => File.join(File.dirname(__FILE__), 'responses', 'specs.4.8.gz')
|
17
|
+
|
18
|
+
FakeWeb.register_uri 'http://github.com:80/technicalpickles/jeweler/blob/master/jeweler.gemspec?raw=true',
|
19
|
+
:response => File.join(File.dirname(__FILE__), 'responses', 'jeweler.gemspec')
|
20
|
+
|
21
|
+
FakeWeb.register_uri 'http://gems.github.com:80/gems/technicalpickles-jeweler-0.9.3.gem',
|
22
|
+
:response => File.join(File.dirname(__FILE__), 'responses', 'technicalpickles-jeweler-0.9.3.gem')
|
23
|
+
|
24
|
+
FakeWeb.register_uri 'http://github.com:80/technicalpickles/bostonrb/blob/master/bostonrb.gemspec?raw=true',
|
25
|
+
:response => File.join(File.dirname(__FILE__), 'responses', 'bostonrb.gemspec')
|
26
|
+
|
27
|
+
FakeWeb.register_uri 'http://github.com:80/technicalpickles/bostonrb/tree/master',
|
28
|
+
:response => File.join(File.dirname(__FILE__), 'responses', 'bostonrb-tree-master')
|
29
|
+
|
30
|
+
FakeWeb.register_uri 'http://github.com:80/technicalpickles/jeweler/tree/master',
|
31
|
+
:response => File.join(File.dirname(__FILE__), 'responses', 'jeweler-tree-master')
|
32
|
+
|
8
33
|
|
9
34
|
class Test::Unit::TestCase
|
10
35
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jeffrafter-gemstalker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Josh Nichols
|
@@ -9,14 +9,14 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-
|
13
|
-
default_executable:
|
12
|
+
date: 2009-04-19 00:00:00 -07:00
|
13
|
+
default_executable:
|
14
14
|
dependencies: []
|
15
15
|
|
16
16
|
description: A library for determining if GitHub has built a gem yet
|
17
17
|
email: josh@technicalpickles.com
|
18
|
-
executables:
|
19
|
-
|
18
|
+
executables: []
|
19
|
+
|
20
20
|
extensions: []
|
21
21
|
|
22
22
|
extra_rdoc_files: []
|
@@ -24,11 +24,19 @@ extra_rdoc_files: []
|
|
24
24
|
files:
|
25
25
|
- LICENSE
|
26
26
|
- Rakefile
|
27
|
-
- README
|
27
|
+
- README.rdoc
|
28
28
|
- VERSION.yml
|
29
|
-
- bin/
|
30
|
-
- lib/
|
29
|
+
- bin/gemstalk
|
30
|
+
- lib/gem_stalker.rb
|
31
31
|
- test/gemstalker_test.rb
|
32
|
+
- test/responses
|
33
|
+
- test/responses/bostonrb-tree-master
|
34
|
+
- test/responses/bostonrb.gemspec
|
35
|
+
- test/responses/jeweler-tree-master
|
36
|
+
- test/responses/jeweler.gemspec
|
37
|
+
- test/responses/specs.4.8.gz
|
38
|
+
- test/responses/technicalpickles-jeweler-0.8.1.gem
|
39
|
+
- test/responses/technicalpickles-jeweler-0.9.3.gem
|
32
40
|
- test/test_helper.rb
|
33
41
|
has_rdoc: false
|
34
42
|
homepage: http://github.com/technicalpickles/gemstalker
|
data/README
DELETED
@@ -1,24 +0,0 @@
|
|
1
|
-
gemstalker
|
2
|
-
==========
|
3
|
-
|
4
|
-
GemStalker is a small library to determine if GitHub has built a gem yet.
|
5
|
-
|
6
|
-
require 'gemstalker'
|
7
|
-
|
8
|
-
stalker = GemStalker.new(:username => 'technicalpickles', :repository => 'jeweler', :version => '0.7.2'
|
9
|
-
|
10
|
-
if stalker.built?
|
11
|
-
puts "zomg, it's built, im so telling everyone"
|
12
|
-
if stalker.in_specfile?
|
13
|
-
puts "sweeeet, i can install it nao"
|
14
|
-
end
|
15
|
-
end
|
16
|
-
|
17
|
-
You can also omit the version, and it will take the version from the repository's gemspec on the master branch.
|
18
|
-
|
19
|
-
Origin code borrowed and inspired by hasmygembuiltyet.org.
|
20
|
-
|
21
|
-
COPYRIGHT
|
22
|
-
=========
|
23
|
-
|
24
|
-
Copyright (c) 2009 Josh Nichols. See LICENSE for details.
|
data/bin/stalk
DELETED
@@ -1,68 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
require 'rubygems'
|
3
|
-
require 'gemstalker'
|
4
|
-
|
5
|
-
def usage
|
6
|
-
puts ""
|
7
|
-
puts "Usage:"
|
8
|
-
puts ""
|
9
|
-
puts " stalk <username> <repository> [version]"
|
10
|
-
puts ""
|
11
|
-
puts "Begins stalking a gem at the specified location e.g. stalk techinicalpickles jeweler"
|
12
|
-
puts ""
|
13
|
-
end
|
14
|
-
|
15
|
-
if ARGV.length == 0 || ARGV.include?("-h") || ARGV.include?("--help")
|
16
|
-
usage
|
17
|
-
exit
|
18
|
-
end
|
19
|
-
|
20
|
-
trap "SIGINT" do
|
21
|
-
puts ""
|
22
|
-
puts "Stopping"
|
23
|
-
exit
|
24
|
-
end
|
25
|
-
|
26
|
-
options = {:username => ARGV[0], :repository => ARGV[1]}
|
27
|
-
options[:version] = ARGV[2] if ARGV.length >= 3
|
28
|
-
stalker = GemStalker.new(options)
|
29
|
-
|
30
|
-
$stdout.sync = true
|
31
|
-
|
32
|
-
if ARGV.length < 3
|
33
|
-
puts "Using version #{stalker.version}"
|
34
|
-
end
|
35
|
-
|
36
|
-
unless stalker.gem?
|
37
|
-
puts "The repository is not configured as a rubygem"
|
38
|
-
puts "Configure the property in the Admin tab of the repository"
|
39
|
-
exit
|
40
|
-
end
|
41
|
-
|
42
|
-
waiting = false
|
43
|
-
|
44
|
-
puts "Checking to see if the gem has been built"
|
45
|
-
loop do
|
46
|
-
if stalker.built?
|
47
|
-
puts "" if waiting
|
48
|
-
puts "=> Zomg, it's built, I'm so telling everyone"
|
49
|
-
break
|
50
|
-
end
|
51
|
-
print "."
|
52
|
-
waiting = true
|
53
|
-
sleep(5)
|
54
|
-
end
|
55
|
-
|
56
|
-
waiting = false
|
57
|
-
|
58
|
-
puts "Checking to see if it is in the specfile"
|
59
|
-
loop do
|
60
|
-
if stalker.in_specfile?
|
61
|
-
puts "" if waiting
|
62
|
-
puts "=> Sweeeet, everyone can install it now"
|
63
|
-
break
|
64
|
-
end
|
65
|
-
print "."
|
66
|
-
waiting = true
|
67
|
-
sleep(5)
|
68
|
-
end
|