brief 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7c6f64e7e55cb875b980ad06e7dbd5e66d0757d7
4
- data.tar.gz: a285a1c7344f503d47c10cec106fe4e18f9a8443
3
+ metadata.gz: 924a794819e31fb5d5a771fcfc1d43a61f9d6d2b
4
+ data.tar.gz: 792080c4446263eeba5d2344b171e969f93c86f8
5
5
  SHA512:
6
- metadata.gz: a97e7f32844a0e7494e619a83ac5d8d08a775331ed97b4083b4833cd5117ad8568c2623048e72c702324ba81c59d508f4a63124b13b431bf4e96e4ef20fc2003
7
- data.tar.gz: 3e5ee5019ef3cf20c4740b1957553b403772b0158b99bb896e449b9649b77b214ccba53fe3008c80f98abebb397397b50680bc395619baa2437b2ffacd8575b0
6
+ metadata.gz: b33ffefd5730676f58566c66819d022c10df5d5282f164cb0db0a50d6a1465727b1d0061320c4db68c96cd8fd441f40615c62d951b15b7b0702eeced3b936f6e
7
+ data.tar.gz: 62342839b618a02b7d720c3151e19e587168dbd9602c5dda6610d34fbbfed0852a1b51e0799a8a466f0f4471e50d6b7e1679d5bda597405f783231f0458f3f1d
data/.gitignore ADDED
@@ -0,0 +1 @@
1
+ *.gem
data/brief.gemspec CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = "brief"
7
- spec.version = '0.0.2'
7
+ spec.version = '0.0.3'
8
8
  spec.authors = ["Jonathan Soeder"]
9
9
  spec.email = ["jonathan.soeder@gmail.com"]
10
10
  spec.description = %q{Brief is a utility to make writing more productive for software architects. It allows you write to places like Github Wiki, The Github Issues API all from the command line and a single file.}
data/lib/brief/github.rb CHANGED
@@ -21,6 +21,69 @@ module Brief
21
21
  end
22
22
  end
23
23
 
24
+ Brief.define "Issue" do
25
+ before(:write) do
26
+ require "brief/github_client"
27
+ !Brief.config.github_repository.nil?
28
+ end
29
+
30
+ before(:publish) do
31
+ require "brief/github_client"
32
+ !Brief.config.github_repository.nil?
33
+ end
34
+
35
+ sample <<-EOF
36
+ # This is the issue title
37
+
38
+ Anything else that you put here will be part of the issue body
39
+ EOF
40
+
41
+ levels do
42
+ level(1) do
43
+ desc "Github Issue"
44
+ define_handler :publish, "Brief::Handlers::GithubIssue"
45
+ end
46
+ end
47
+ end
48
+
49
+ Brief.define "Milestone with issues" do
50
+ before(:write) do
51
+ require "brief/github_client"
52
+ !Brief.config.github_repository.nil?
53
+ end
54
+
55
+ before(:publish) do
56
+ require "brief/github_client"
57
+ !Brief.config.github_repository.nil?
58
+ end
59
+
60
+ sample <<-EOF
61
+ # This is a milestone heading
62
+
63
+ A milestone is some logical way of grouping issues and attaching a date to them. You will write the body
64
+ of the individual issues and optionally assign them or label them by writing them below. When this brief
65
+ gets published, the issues will be created and added to the milestone.
66
+
67
+ ## This is an issue that belongs to the above milestone
68
+
69
+ The content of your issue goes here. Normal github flavored markdown is supported.
70
+ EOF
71
+
72
+ levels do
73
+ level(1) do
74
+ desc "Github Milestone"
75
+ define_handler :publish, "Brief::Handlers::GithubMilestone"
76
+ replaces_items_from_level 3, :with => nil
77
+ end
78
+
79
+ level(2) do
80
+ desc "Github Issue"
81
+ define_handler :publish, "Brief::Handlers::GithubIssue"
82
+ end
83
+ end
84
+ end
85
+
86
+
24
87
  Brief.define "Project Overview" do
25
88
  aliases :overview, :project_overview
26
89
 
data/lib/brief/tree.rb CHANGED
@@ -16,10 +16,11 @@ module Brief
16
16
  visitor = lambda do |child|
17
17
  c_only = child.except(:children)
18
18
  g_children = Array(child[:children])
19
- g_children = nil if g_children.length == 0
20
19
 
21
20
  g_children.each {|gchild| gchild.parent_id = c_only.id}
22
21
 
22
+ g_children = nil if g_children.length == 0
23
+
23
24
  [c_only, g_children].compact
24
25
  end
25
26
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: brief
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonathan Soeder
@@ -188,6 +188,7 @@ executables:
188
188
  extensions: []
189
189
  extra_rdoc_files: []
190
190
  files:
191
+ - .gitignore
191
192
  - Gemfile
192
193
  - Gemfile.lock
193
194
  - Guardfile
@@ -195,7 +196,6 @@ files:
195
196
  - README.md
196
197
  - Rakefile
197
198
  - bin/brief
198
- - brief-0.0.1.gem
199
199
  - brief.gemspec
200
200
  - examples/project_overview.md
201
201
  - lib/brief.rb
data/brief-0.0.1.gem DELETED
Binary file