tracker-client 0.4 → 0.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/lib/command.rb +8 -1
  2. metadata +1 -1
data/lib/command.rb CHANGED
@@ -127,6 +127,7 @@ module Tracker
127
127
  # Remove messages from Array
128
128
  patches.pop
129
129
  puts
130
+ counter = 0
130
131
  patches.each do |p|
131
132
  begin
132
133
  response = RestClient.get(
@@ -138,11 +139,17 @@ module Tracker
138
139
  )
139
140
  response = JSON::parse(response)
140
141
  puts '[%s][%s][rev%s] %s' % [response['commit'][-8, 8], response['status'].upcase, response['revision'], response['message']]
142
+ counter+=1
141
143
  rescue => e
144
+ next if response == 'null'
142
145
  puts '[ERR][%s] %s' % [p['hashes']['commit'][-8, 8], e.message]
143
146
  end
144
147
  end
145
- " |\n |--------> [%s]\n\n" % config[:url]
148
+ if counter == 0
149
+ "ERR: This branch is not recorded yet. ($ tracker record)\n\n"
150
+ else
151
+ " |\n |--------> [%s]\n\n" % config[:url]
152
+ end
146
153
  end
147
154
 
148
155
  private
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tracker-client
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.4'
4
+ version: '0.5'
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: