vain 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
data/bin/vain CHANGED
@@ -1,7 +1,6 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- require 'rubygems'
4
- require 'vain'
3
+ require File.dirname(__FILE__) + '/../lib/vain'
5
4
 
6
5
  console = Vain::CLI.new
7
6
  console.start
data/lib/vain/cli.rb CHANGED
@@ -23,7 +23,7 @@ module Vain
23
23
  def status(user_handle)
24
24
  user = Vain::Github::User.get(user_handle)
25
25
  return failtown("Unknown user: #{user_handle}") if user.nil?
26
- puts "#{CommandColor}#{user.login}#{DefaultColor} - #{user.followers_count} followers - #{user.public_repo_count} public repositories"
26
+ puts "#{CommandColor}#{user.login}#{DefaultColor} - #{user.followers} followers - #{user.public_repos} public repositories"
27
27
  # get the repositories sorted by watcher count
28
28
  repositories = Vain::Github::Repo.all(user_handle).sort_by { |r| 1.0 / r.watchers }
29
29
  data = repositories.map do |repo|
data/lib/vain/github.rb CHANGED
@@ -25,7 +25,7 @@ module Vain
25
25
  page = 1
26
26
  begin
27
27
  response = RestClient.get("https://api.github.com/users/#{user_name}/repos?page=#{page}")
28
- repos = JSON.parse(response)["repositories"]
28
+ repos = JSON.parse(response)
29
29
  all_repos.concat repos.map { |hash| Repo.new(hash) }
30
30
  page += 1
31
31
  end while repos.size == 30
data/lib/vain/version.rb CHANGED
@@ -6,6 +6,6 @@ module Vain
6
6
 
7
7
  private
8
8
 
9
- VERSION = [0, 1, 0]
9
+ VERSION = [0, 1, 1]
10
10
 
11
11
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vain
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -13,7 +13,7 @@ date: 2012-02-13 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: columnizer
16
- requirement: &2153465840 !ruby/object:Gem::Requirement
16
+ requirement: &2157058440 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - =
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 0.0.3
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *2153465840
24
+ version_requirements: *2157058440
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: rest-client
27
- requirement: &2153465220 !ruby/object:Gem::Requirement
27
+ requirement: &2157057840 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ~>
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: '1.6'
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *2153465220
35
+ version_requirements: *2157057840
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: json_pure
38
- requirement: &2153464720 !ruby/object:Gem::Requirement
38
+ requirement: &2157057320 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ~>
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: 1.4.6
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *2153464720
46
+ version_requirements: *2157057320
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: hashie
49
- requirement: &2153464180 !ruby/object:Gem::Requirement
49
+ requirement: &2157056740 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ~>
@@ -54,7 +54,7 @@ dependencies:
54
54
  version: '1.0'
55
55
  type: :runtime
56
56
  prerelease: false
57
- version_requirements: *2153464180
57
+ version_requirements: *2157056740
58
58
  description: View information about a GitHub account
59
59
  email: john@crepezzi.com
60
60
  executables: