bl 0.5.6 → 0.5.7

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3fb625a30492132d3223a78bdbb7d77a5ba092c4
4
- data.tar.gz: 0c79630777e849df8217f020da3bd5a003fa6daa
3
+ metadata.gz: c9792c82d235eeb267bd5134fdb77200e034194d
4
+ data.tar.gz: 57e9ff35fcacbf11606c698c87de0dbfc1cac04d
5
5
  SHA512:
6
- metadata.gz: 6e598e8c63ed39dfdaf0aad3cd0034c78d100de8b6576b84a4c76b452b1e79be272cdbea4bdacf057aed7f080330877a0f1ed02355801b502573eb777e6be2ba
7
- data.tar.gz: e397cec10fbe32d63db08f6027a76d990257ff6c84d95217e5a7178c9c3cfdd8d6aa6d580815e80cd66cbd5b7149951d6c7123e7a7a565dcb69acb4b46aa9ecd
6
+ metadata.gz: 6d347954df6704b513ffc9dfffec6924beebfbf68fbae52a58255efd7819180c954e38ebeca8a5a71c7a5d466d17bfa4302710a872949b3d6ecff22494b14ba3
7
+ data.tar.gz: 0b658a99c865e110430b4e7235cda45e902de6189e8ae5ba773dc9e77f48199c61cd6bf3d0a07763cacae45daa6e9ffc066fb2871d9f0c3ddb84b03f02c71ec7
data/README.md CHANGED
@@ -59,12 +59,12 @@ Commands:
59
59
  bl edit KEY # edit issues' description by $EDITOR
60
60
  bl file SUBCOMMAND ...ARGS # manage files
61
61
  bl gitrepo SUBCOMMAND ...ARGS # show gitrepos
62
- bl groups SUBCOMMAND ...ARGS #
62
+ bl groups SUBCOMMAND ...ARGS # manage groups
63
63
  bl help [COMMAND] # Describe available commands or one specific command
64
64
  bl init # initialize a default config file
65
65
  bl list # list issues by typical ways
66
66
  bl milestone SUBCOMMAND ...ARGS # manage milestones
67
- bl notifications SUBCOMMAND ...ARGS #
67
+ bl notifications SUBCOMMAND ...ARGS # manage notifications
68
68
  bl priorities # list priorities
69
69
  bl project SUBCOMMAND ...ARGS # manage projects
70
70
  bl recent SUBCOMMAND ...ARGS # list recent stuff
@@ -72,14 +72,14 @@ Commands:
72
72
  bl roles # list roles
73
73
  bl search # search issues
74
74
  bl show KEY # show an issue's details
75
- bl space SUBCOMMAND ...ARGS #
75
+ bl space SUBCOMMAND ...ARGS # manage space
76
76
  bl statuses # list statuses
77
77
  bl type SUBCOMMAND ...ARGS # manage types
78
78
  bl update [KEY...] # update issues
79
- bl users SUBCOMMAND ...ARGS #
79
+ bl users SUBCOMMAND ...ARGS # manage users
80
80
  bl version # show version
81
- bl watchings SUBCOMMAND ...ARGS #
82
- bl webhooks SUBCOMMAND ...ARGS #
81
+ bl watchings SUBCOMMAND ...ARGS # manage watchings
82
+ bl webhooks SUBCOMMAND ...ARGS # manage webhooks
83
83
  bl wiki SUBCOMMAND ...ARGS # manage wikis
84
84
 
85
85
  Options:
@@ -11,12 +11,12 @@ Commands:
11
11
  bl edit KEY # edit issues' description by $EDITOR
12
12
  bl file SUBCOMMAND ...ARGS # manage files
13
13
  bl gitrepo SUBCOMMAND ...ARGS # show gitrepos
14
- bl groups SUBCOMMAND ...ARGS #
14
+ bl groups SUBCOMMAND ...ARGS # manage groups
15
15
  bl help [COMMAND] # Describe available commands or one specific command
16
16
  bl init # initialize a default config file
17
17
  bl list # list issues by typical ways
18
18
  bl milestone SUBCOMMAND ...ARGS # manage milestones
19
- bl notifications SUBCOMMAND ...ARGS #
19
+ bl notifications SUBCOMMAND ...ARGS # manage notifications
20
20
  bl priorities # list priorities
21
21
  bl project SUBCOMMAND ...ARGS # manage projects
22
22
  bl recent SUBCOMMAND ...ARGS # list recent stuff
@@ -24,14 +24,14 @@ Commands:
24
24
  bl roles # list roles
25
25
  bl search # search issues
26
26
  bl show KEY # show an issue's details
27
- bl space SUBCOMMAND ...ARGS #
27
+ bl space SUBCOMMAND ...ARGS # manage space
28
28
  bl statuses # list statuses
29
29
  bl type SUBCOMMAND ...ARGS # manage types
30
30
  bl update [KEY...] # update issues
31
- bl users SUBCOMMAND ...ARGS #
31
+ bl users SUBCOMMAND ...ARGS # manage users
32
32
  bl version # show version
33
- bl watchings SUBCOMMAND ...ARGS #
34
- bl webhooks SUBCOMMAND ...ARGS #
33
+ bl watchings SUBCOMMAND ...ARGS # manage watchings
34
+ bl webhooks SUBCOMMAND ...ARGS # manage webhooks
35
35
  bl wiki SUBCOMMAND ...ARGS # manage wikis
36
36
 
37
37
  Options:
@@ -77,14 +77,14 @@ module Bl
77
77
  end
78
78
  opts[:categoryId] = [-1] if options[:nocategory]
79
79
  res = client.get('issues', opts)
80
- puts formatter.render(res.body, fields: ISSUE_FIELDS, max_width: TPUT_COLS)
80
+ print_issue_response(res)
81
81
  end
82
82
 
83
83
  desc 'search', 'search issues'
84
84
  options ISSUES_PARAMS
85
85
  def search
86
86
  res = client.get('issues', delete_class_options(options.to_h))
87
- puts formatter.render(res.body, fields: ISSUE_FIELDS, max_width: TPUT_COLS)
87
+ print_issue_response(res)
88
88
  end
89
89
 
90
90
  desc 'show KEY', "show an issue's details"
@@ -135,7 +135,8 @@ module Bl
135
135
  'issues',
136
136
  issue_default_options.merge({summary: s}).merge(delete_class_options(options.to_h))
137
137
  )
138
- puts "issue added: #{res.body.issueKey}\t#{res.body.summary}"
138
+ puts 'issue added'
139
+ print_issue_response(res)
139
140
  end
140
141
  end
141
142
 
@@ -145,7 +146,8 @@ module Bl
145
146
  def update(*keys)
146
147
  keys.each do |k|
147
148
  res = client.patch("issues/#{k}", delete_class_options(options.to_h))
148
- puts "issue updated: #{res.body.issueKey}\t#{res.body.summary}"
149
+ puts 'issue updated'
150
+ print_issue_response(res)
149
151
  end
150
152
  end
151
153
 
@@ -153,7 +155,8 @@ module Bl
153
155
  def close(*keys)
154
156
  keys.each do |k|
155
157
  res = client.patch("issues/#{k}", statusId: 4)
156
- puts "issue closed: #{res.body.issueKey}\t#{res.body.summary}"
158
+ puts 'issue closed'
159
+ print_issue_response(res)
157
160
  end
158
161
  end
159
162
 
@@ -207,13 +210,13 @@ module Bl
207
210
  desc 'gitrepo SUBCOMMAND ...ARGS', 'show gitrepos'
208
211
  subcommand 'gitrepo', GitRepo
209
212
 
210
- desc 'groups SUBCOMMAND ...ARGS', ''
213
+ desc 'groups SUBCOMMAND ...ARGS', 'manage groups'
211
214
  subcommand 'groups', Groups
212
215
 
213
216
  desc 'milestone SUBCOMMAND ...ARGS', 'manage milestones'
214
217
  subcommand 'milestone', Milestone
215
218
 
216
- desc 'notifications SUBCOMMAND ...ARGS', ''
219
+ desc 'notifications SUBCOMMAND ...ARGS', 'manage notifications'
217
220
  subcommand 'notifications', Notifications
218
221
 
219
222
  desc 'project SUBCOMMAND ...ARGS', 'manage projects'
@@ -222,23 +225,28 @@ module Bl
222
225
  desc 'recent SUBCOMMAND ...ARGS', 'list recent stuff'
223
226
  subcommand 'recent', Recent
224
227
 
225
- desc 'space SUBCOMMAND ...ARGS', ''
228
+ desc 'space SUBCOMMAND ...ARGS', 'manage space'
226
229
  subcommand 'space', Space
227
230
 
228
231
  desc 'type SUBCOMMAND ...ARGS', 'manage types'
229
232
  subcommand 'type', Type
230
233
 
231
- desc 'users SUBCOMMAND ...ARGS', ''
234
+ desc 'users SUBCOMMAND ...ARGS', 'manage users'
232
235
  subcommand 'users', Users
233
236
 
234
- desc 'watchings SUBCOMMAND ...ARGS', ''
237
+ desc 'watchings SUBCOMMAND ...ARGS', 'manage watchings'
235
238
  subcommand 'watchings', Watchings
236
239
 
237
- desc 'webhooks SUBCOMMAND ...ARGS', ''
240
+ desc 'webhooks SUBCOMMAND ...ARGS', 'manage webhooks'
238
241
  subcommand 'webhooks', Webhooks
239
242
 
240
243
  desc 'wiki SUBCOMMAND ...ARGS', 'manage wikis'
241
244
  subcommand 'wiki', Wiki
242
245
 
246
+ private
247
+
248
+ def print_issue_response(res)
249
+ puts formatter.render(res.body, fields: ISSUE_FIELDS, max_width: TPUT_COLS)
250
+ end
243
251
  end
244
252
  end
@@ -12,6 +12,12 @@ module Bl
12
12
  print_response(res)
13
13
  end
14
14
 
15
+ desc 'show', 'show project'
16
+ def show(id)
17
+ res = client.get("#{@url}/#{id}")
18
+ print_response(res)
19
+ end
20
+
15
21
  desc 'add', 'add project'
16
22
  option :key, required: true, type: :string
17
23
  option :chartEnabled, type: :boolean, default: false
@@ -1,3 +1,3 @@
1
1
  module Bl
2
- VERSION = '0.5.6'.freeze
2
+ VERSION = '0.5.7'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bl
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.6
4
+ version: 0.5.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - saki
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-04-18 00:00:00.000000000 Z
11
+ date: 2017-04-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor