punchlist 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/punchlist.rb +9 -4
- data/lib/punchlist/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5e83dc434aafca7c85c72221ac0a8327b3ec19ea
|
4
|
+
data.tar.gz: 575957e7f721877fce24d8366d09e42c97e63d5b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d59c636e7382621dc0ff81e94faec5262c8ccc53d660132e79cf0b7969a30d4f07d2382a881092e028baa6696d7cee4d74025a637b3fc2aaf9ad90f088d8775
|
7
|
+
data.tar.gz: 6564e53503c64110055c93d8cfffe7c97a3f86d29d83c0aafa865d770c4b97de565c638e99c8632d1f2b3a26709f04a84295fe8d4337f99cfcbef6b0deb73559
|
data/lib/punchlist.rb
CHANGED
@@ -1,3 +1,6 @@
|
|
1
|
+
# XXX: need to include BUG in list
|
2
|
+
# XXX: need to include BUG in my rubocop config
|
3
|
+
# BUG need to fix the fact that we create blank lines on files with no issues
|
1
4
|
module Punchlist
|
2
5
|
# Counts the number of 'todo' comments in your code.
|
3
6
|
class Punchlist
|
@@ -30,10 +33,11 @@ module Punchlist
|
|
30
33
|
end
|
31
34
|
|
32
35
|
def analyze_files
|
36
|
+
all_output = []
|
33
37
|
source_files.each do |filename|
|
34
|
-
|
35
|
-
@outputter.puts render(output)
|
38
|
+
all_output.concat(look_for_punchlist_items(filename))
|
36
39
|
end
|
40
|
+
@outputter.print render(all_output)
|
37
41
|
end
|
38
42
|
|
39
43
|
def source_files
|
@@ -57,9 +61,10 @@ module Punchlist
|
|
57
61
|
end
|
58
62
|
|
59
63
|
def render(output)
|
60
|
-
output.map do |filename, line_num, line|
|
64
|
+
lines = output.map do |filename, line_num, line|
|
61
65
|
"#{filename}:#{line_num}: #{line}"
|
62
|
-
end
|
66
|
+
end
|
67
|
+
lines.join
|
63
68
|
end
|
64
69
|
end
|
65
70
|
end
|
data/lib/punchlist/version.rb
CHANGED