rake-notes 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +0 -1
- data/Gemfile.lock +28 -0
- data/lib/rake/notes/source_annotation_extractor.rb +12 -2
- data/lib/rake/notes/version.rb +1 -1
- data/rake-notes.gemspec +1 -0
- metadata +18 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7a118adeee9933454b2484edf35ea8393d6290e4
|
4
|
+
data.tar.gz: 0d9b5740f02e3fa0f58654bbc6136d4758582140
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 87ad039547d084a3afe5453b843d63cd8bc7edaae1a283c015b3266d58658e7b09bf602e249b41b898f80f4403e4dfd602c8c5d811f832993138c77cda7c4428
|
7
|
+
data.tar.gz: e11bc0ac466b0f30a3e253154a9f89ab9fe977db33431766665379aa1f7bc14c0239727067c42ed0bc87b4857645cbe004dadedaf173ddbefa8a449597f99d88
|
data/.gitignore
CHANGED
data/Gemfile.lock
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
rake-notes (0.2.0)
|
5
|
+
colored
|
6
|
+
rake
|
7
|
+
|
8
|
+
GEM
|
9
|
+
remote: https://rubygems.org/
|
10
|
+
specs:
|
11
|
+
colored (1.2)
|
12
|
+
diff-lcs (1.1.3)
|
13
|
+
rake (10.1.0)
|
14
|
+
rspec (2.11.0)
|
15
|
+
rspec-core (~> 2.11.0)
|
16
|
+
rspec-expectations (~> 2.11.0)
|
17
|
+
rspec-mocks (~> 2.11.0)
|
18
|
+
rspec-core (2.11.1)
|
19
|
+
rspec-expectations (2.11.3)
|
20
|
+
diff-lcs (~> 1.1.3)
|
21
|
+
rspec-mocks (2.11.3)
|
22
|
+
|
23
|
+
PLATFORMS
|
24
|
+
ruby
|
25
|
+
|
26
|
+
DEPENDENCIES
|
27
|
+
rake-notes!
|
28
|
+
rspec
|
@@ -1,3 +1,5 @@
|
|
1
|
+
require 'colored'
|
2
|
+
|
1
3
|
module Rake
|
2
4
|
module Notes
|
3
5
|
# From:
|
@@ -21,6 +23,13 @@ module Rake
|
|
21
23
|
RUBYFILES = %w( Vagrantfile Rakefile Puppetfile Gemfile )
|
22
24
|
|
23
25
|
class Annotation < Struct.new(:line, :tag, :text)
|
26
|
+
|
27
|
+
COLORS = {
|
28
|
+
'OPTIMIZE' => 'cyan',
|
29
|
+
'FIXME' => 'magenta',
|
30
|
+
'TODO' => 'yellow'
|
31
|
+
}
|
32
|
+
|
24
33
|
# Returns a representation of the annotation that looks like this:
|
25
34
|
#
|
26
35
|
# [126] [TODO] This algorithm is simple and clearly correct, make it faster.
|
@@ -28,8 +37,9 @@ module Rake
|
|
28
37
|
# If +options+ has a flag <tt>:tag</tt> the tag is shown as in the example above.
|
29
38
|
# Otherwise the string contains just line and text.
|
30
39
|
def to_s(options={})
|
31
|
-
|
32
|
-
s
|
40
|
+
colored_tag = COLORS[tag.to_s].nil? ? tag : tag.send(COLORS[tag.to_s])
|
41
|
+
s = "[#{line.to_s.rjust(options[:indent]).green}] "
|
42
|
+
s << "[#{colored_tag}] " if options[:tag]
|
33
43
|
s << text
|
34
44
|
end
|
35
45
|
end
|
data/lib/rake/notes/version.rb
CHANGED
data/rake-notes.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rake-notes
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fabio Rehm
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-10-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -24,6 +24,20 @@ dependencies:
|
|
24
24
|
- - '>='
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: colored
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - '>='
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - '>='
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
27
41
|
- !ruby/object:Gem::Dependency
|
28
42
|
name: rspec
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -48,6 +62,7 @@ files:
|
|
48
62
|
- .gitignore
|
49
63
|
- .rspec
|
50
64
|
- Gemfile
|
65
|
+
- Gemfile.lock
|
51
66
|
- LICENSE.txt
|
52
67
|
- README.md
|
53
68
|
- Rakefile
|
@@ -77,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
77
92
|
version: '0'
|
78
93
|
requirements: []
|
79
94
|
rubyforge_project:
|
80
|
-
rubygems_version: 2.
|
95
|
+
rubygems_version: 2.1.5
|
81
96
|
signing_key:
|
82
97
|
specification_version: 4
|
83
98
|
summary: rake notes task for non-Rails' projects
|