bl 0.0.18 → 0.1.0

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: ad4bf727d88d7db10b943cb746c7fae8d5a4c56a
4
- data.tar.gz: 1c4e165df3c2925a0903987542407604289dbea7
3
+ metadata.gz: d7e2420b1660f8771ae2eef0f7206b1332026711
4
+ data.tar.gz: c709b389d3fb5e07d59a8c448299e0f4669db5ed
5
5
  SHA512:
6
- metadata.gz: c2adffd8959a0166d98d8dc39574c9891391022ba673bfc6b5f1b87b661da69d307e928eb31325d1af50ffad8296f7f5242bd76166711205b95b74dfe132ea5a
7
- data.tar.gz: 55d89e37cf36f10a84b8eeef9f28aca618419ecdcd6e6cc237400a00984d475909393adeab0094aae378430b5cc7e2f874c4ac436f2bae78c9958424490474b9
6
+ metadata.gz: 7aa0333f407668b3208bd54939b25358096d2e67200573a29399bd148e3e3745fdce7a6110d54b0b00addb96b2ddfc0c2a7362e0d23fa0b51e61d2202bf7938b
7
+ data.tar.gz: 99d0098b31dec3eada50ae29e46339a57000432fcbcadd7d06fe6ecbe82e202e470000fe02a2e9f7fce93a414a3be3b8ef2122d5f0120203ac9c7ec3b55ff432
data/README.md CHANGED
@@ -1,3 +1,5 @@
1
+ [![Gem Version](https://badge.fury.io/rb/bl.svg)](https://badge.fury.io/rb/bl)
2
+
1
3
  # bl
2
4
 
3
5
  bl is a command line tool for [Backlog](http://www.backlog.jp/).
@@ -24,7 +26,7 @@ bl uses `~/.bl.yml` for configuration.
24
26
  bl activities # list activities
25
27
  bl add [SUBJECT...] # add issues
26
28
  bl browse KEY # browse an issue
27
- bl category SUBCOMMAND ...ARGS # manage categoryies
29
+ bl category SUBCOMMAND ...ARGS # manage categories
28
30
  bl close [KEY...] # close issues
29
31
  bl config # show config
30
32
  bl count # count issues
@@ -45,16 +47,35 @@ bl uses `~/.bl.yml` for configuration.
45
47
  bl wiki SUBCOMMAND ...ARGS # manage wikis
46
48
 
47
49
 
48
- ### Example
50
+ ### Examples
49
51
 
50
- update unassigned issues
52
+ view global or command specific help:
51
53
 
52
- bl list --unassigned | awk '{print $2}' | xargs bl update --assigneeId 12345
54
+ bl help
55
+ bl help list
56
+ bl help search
57
+ bl help add
58
+
59
+ list overdue issues
60
+
61
+ bl list --overdue
62
+
63
+ add an issue
64
+
65
+ bl add "Update OpenSSL immediately" --priorityId 2 --assigneeId 11111 --dueDate 2014-04-07
53
66
 
54
67
  add multi issues on list.txt
55
68
 
56
69
  cat list.txt | xargs -I {} bl add {}
57
70
 
71
+ update unassigned issues
72
+
73
+ bl list --unassigned | awk '{print $2}' | xargs bl update --assigneeId 12345
74
+
75
+
76
+ ## Backlog API
77
+
78
+ http://developer.nulab-inc.com/docs/backlog
58
79
 
59
80
  ## Contributing
60
81
 
@@ -46,6 +46,12 @@ module Bl
46
46
  end
47
47
  end
48
48
 
49
+ desc 'space', 'show space info'
50
+ def space
51
+ res = client.get('space').body
52
+ puts res.inspect
53
+ end
54
+
49
55
  desc 'count', 'count issues'
50
56
  def count
51
57
  puts client.get('issues/count').body.count
@@ -138,15 +144,10 @@ module Bl
138
144
  options ISSUE_BASE_ATTRIBUTES
139
145
  def add(*subjects)
140
146
  subjects.each do |s|
141
- base_options = {
142
- projectId: @config[:issue][:default_project_id].to_i,
143
- summary: s,
144
- issueTypeId: @config[:issue][:default_issue_type_id].to_i,
145
- priorityId: @config[:issue][:default_priority_id].to_i
146
- }
147
+ issue_default_options = @config[:issue][:default]
147
148
  res = client.post(
148
149
  'issues',
149
- base_options.merge(options)
150
+ issue_default_options.merge({summary: s}).merge(options)
150
151
  )
151
152
  puts "issue added: #{res.body.issueKey}\t#{res.body.summary}"
152
153
  end
@@ -205,10 +206,17 @@ module Bl
205
206
  end
206
207
  end
207
208
 
209
+ desc 'notifications', 'list notifications'
210
+ def notifications
211
+ client.get('notifications').body.each do |n|
212
+ puts n.pretty_inspect
213
+ end
214
+ end
215
+
208
216
  desc 'type SUBCOMMAND ...ARGS', 'manage types'
209
217
  subcommand 'type', Type
210
218
 
211
- desc 'category SUBCOMMAND ...ARGS', 'manage categoryies'
219
+ desc 'category SUBCOMMAND ...ARGS', 'manage categories'
212
220
  subcommand 'category', Category
213
221
 
214
222
  desc 'milestone SUBCOMMAND ...ARGS', 'manage milestones'
@@ -26,9 +26,11 @@ module Bl
26
26
  api_key: '',
27
27
  project_key: '',
28
28
  issue: {
29
- default_project_id: '',
30
- default_issue_type_id: '',
31
- default_priority_id: ''
29
+ default: {
30
+ projectId: nil,
31
+ issueTypeId: nil,
32
+ priorityId: 3
33
+ }
32
34
  }
33
35
  }
34
36
  end
@@ -1,3 +1,3 @@
1
1
  module Bl
2
- VERSION = '0.0.18'.freeze
2
+ VERSION = '0.1.0'.freeze
3
3
  end
@@ -0,0 +1,3 @@
1
+ linter:
2
+ rubocop:
3
+ options:
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.0.18
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - saki
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-05-11 00:00:00.000000000 Z
11
+ date: 2016-05-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor
@@ -152,6 +152,7 @@ files:
152
152
  - lib/bl/type.rb
153
153
  - lib/bl/version.rb
154
154
  - lib/bl/wiki.rb
155
+ - sideci.yml
155
156
  homepage: https://github.com/sakihet/bl
156
157
  licenses:
157
158
  - MIT