rake-notes 0.2.1 → 1.0.0.beta
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 +4 -4
- data/.gitignore +2 -0
- data/.ruby-version +1 -0
- data/Gemfile.lock +18 -12
- data/lib/rake/notes/source_annotation_extractor.rb +3 -1
- data/lib/rake/notes/version.rb +1 -1
- data/spec/rake/notes/source_annotation_extractor_spec.rb +12 -2
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d8b93947bbdaf5770ba2a9c1fed4afaee4329ce87a7ba5b58f6f3eb166cb49f
|
4
|
+
data.tar.gz: 521551c6b1c07735296a22984b03cba78bfc5794874ca7e37d509c2f1dc3b9e5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f579ad64a538192373e3cb894c3598167c29ae3e8fc4a7c503a9e6a02328107d94d270a999fe98e0890846c3dba3460a34c23351ce6baaea38e71ebf97586b26
|
7
|
+
data.tar.gz: 5178386714e9fb69972ef0bd7b659f46e8204949c6415869c20f49961b08cf6438e090b457dffc2125926af5fe93fd91b85fb6d2518da560ad01930ffc89e07c
|
data/.gitignore
CHANGED
data/.ruby-version
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
3.3.2
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
rake-notes (0.
|
4
|
+
rake-notes (1.0.0.beta)
|
5
5
|
colored
|
6
6
|
rake
|
7
7
|
|
@@ -9,23 +9,29 @@ GEM
|
|
9
9
|
remote: https://rubygems.org/
|
10
10
|
specs:
|
11
11
|
colored (1.2)
|
12
|
-
diff-lcs (1.1
|
13
|
-
rake (
|
14
|
-
rspec (
|
15
|
-
rspec-core (~>
|
16
|
-
rspec-expectations (~>
|
17
|
-
rspec-mocks (~>
|
18
|
-
rspec-core (
|
19
|
-
|
20
|
-
|
21
|
-
|
12
|
+
diff-lcs (1.5.1)
|
13
|
+
rake (13.2.1)
|
14
|
+
rspec (3.13.0)
|
15
|
+
rspec-core (~> 3.13.0)
|
16
|
+
rspec-expectations (~> 3.13.0)
|
17
|
+
rspec-mocks (~> 3.13.0)
|
18
|
+
rspec-core (3.13.0)
|
19
|
+
rspec-support (~> 3.13.0)
|
20
|
+
rspec-expectations (3.13.0)
|
21
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
22
|
+
rspec-support (~> 3.13.0)
|
23
|
+
rspec-mocks (3.13.1)
|
24
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
25
|
+
rspec-support (~> 3.13.0)
|
26
|
+
rspec-support (3.13.1)
|
22
27
|
|
23
28
|
PLATFORMS
|
24
29
|
ruby
|
30
|
+
x86_64-linux
|
25
31
|
|
26
32
|
DEPENDENCIES
|
27
33
|
rake-notes!
|
28
34
|
rspec
|
29
35
|
|
30
36
|
BUNDLED WITH
|
31
|
-
|
37
|
+
2.5.9
|
@@ -89,7 +89,7 @@ module Rake
|
|
89
89
|
results.update(find_in(item))
|
90
90
|
elsif item =~ /\.(builder|rb|coffee|rake|pp|ya?ml|gemspec|feature)$/ || RUBYFILES.include?(File.basename(item))
|
91
91
|
results.update(extract_annotations_from(item, /#\s*(#{tag}):?\s*(.*)$/))
|
92
|
-
elsif item =~ /\.(css|scss|js)$/
|
92
|
+
elsif item =~ /\.(css|scss|js|ts|tsx)$/
|
93
93
|
results.update(extract_annotations_from(item, /\/\/\s*(#{tag}):?\s*(.*)$/))
|
94
94
|
elsif item =~ /\.erb$/
|
95
95
|
results.update(extract_annotations_from(item, /<%\s*#\s*(#{tag}):?\s*(.*?)\s*%>/))
|
@@ -97,6 +97,8 @@ module Rake
|
|
97
97
|
results.update(extract_annotations_from(item, /-\s*#\s*(#{tag}):?\s*(.*)$/))
|
98
98
|
elsif item =~ /\.slim$/
|
99
99
|
results.update(extract_annotations_from(item, /\/\s*\s*(#{tag}):?\s*(.*)$/))
|
100
|
+
elsif item =~ /\.md$/
|
101
|
+
results.update(extract_annotations_from(item, /\*\*\s*(#{tag})\**:?\s*(.*)\**$/))
|
100
102
|
end
|
101
103
|
end
|
102
104
|
|
data/lib/rake/notes/version.rb
CHANGED
@@ -3,8 +3,6 @@ require 'spec_helper'
|
|
3
3
|
require 'rake/notes/source_annotation_extractor'
|
4
4
|
|
5
5
|
describe Rake::Notes::SourceAnnotationExtractor do
|
6
|
-
let(:fixture_path) { "#{Dir.pwd}/.tmp" }
|
7
|
-
|
8
6
|
before do
|
9
7
|
@current_path = Dir.pwd
|
10
8
|
Dir.mkdir(fixture_path) unless Dir.exist?(fixture_path)
|
@@ -30,6 +28,8 @@ describe Rake::Notes::SourceAnnotationExtractor do
|
|
30
28
|
fixture_file "application.js", "// TODO: note in js"
|
31
29
|
fixture_file "application.css", "// TODO: note in css"
|
32
30
|
fixture_file "application.css.scss", "// TODO: note in scss"
|
31
|
+
fixture_file "component.tsx", "// TODO: note in tsx"
|
32
|
+
fixture_file "application.ts", "// TODO note in ts"
|
33
33
|
fixture_file "application_controller.rb", 1000.times.map { "" }.join("\n") << "# TODO: note in ruby"
|
34
34
|
fixture_file "task.rake", "# TODO: note in rake"
|
35
35
|
fixture_file "init.pp", "# TODO: note in puppet"
|
@@ -41,6 +41,8 @@ describe Rake::Notes::SourceAnnotationExtractor do
|
|
41
41
|
fixture_file "Puppetfile", "# TODO: note in puppetfile"
|
42
42
|
fixture_file "Gemfile", "# TODO: note in gemfile"
|
43
43
|
fixture_file "feature.feature", "# TODO: note in cucumber feature"
|
44
|
+
fixture_file "README.md", "**TODO**: note in markdown version one"
|
45
|
+
fixture_file "CONTRIBUTING.md", "**TODO: note in markdown version two**"
|
44
46
|
end
|
45
47
|
|
46
48
|
it { should match(/note in erb/) }
|
@@ -51,6 +53,8 @@ describe Rake::Notes::SourceAnnotationExtractor do
|
|
51
53
|
it { should match(/note in js/) }
|
52
54
|
it { should match(/note in css/) }
|
53
55
|
it { should match(/note in scss/) }
|
56
|
+
it { should match(/note in tsx/) }
|
57
|
+
it { should match(/note in ts/) }
|
54
58
|
it { should match(/note in rake/) }
|
55
59
|
it { should match(/note in puppet/) }
|
56
60
|
it { should match(/note in yml/) }
|
@@ -61,6 +65,8 @@ describe Rake::Notes::SourceAnnotationExtractor do
|
|
61
65
|
it { should match(/note in puppetfile/) }
|
62
66
|
it { should match(/note in gemfile/) }
|
63
67
|
it { should match(/note in cucumber feature/) }
|
68
|
+
it { should match(/note in markdown version one/) }
|
69
|
+
it { should match(/note in markdown version two/) }
|
64
70
|
end
|
65
71
|
|
66
72
|
def fixture_file(path, contents)
|
@@ -69,4 +75,8 @@ describe Rake::Notes::SourceAnnotationExtractor do
|
|
69
75
|
f.puts contents
|
70
76
|
end
|
71
77
|
end
|
78
|
+
|
79
|
+
def fixture_path
|
80
|
+
"#{Dir.pwd}/.tmp"
|
81
|
+
end
|
72
82
|
end
|
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: 1.0.0.beta
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fabio Rehm
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-06-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -61,6 +61,7 @@ extra_rdoc_files: []
|
|
61
61
|
files:
|
62
62
|
- ".gitignore"
|
63
63
|
- ".rspec"
|
64
|
+
- ".ruby-version"
|
64
65
|
- Gemfile
|
65
66
|
- Gemfile.lock
|
66
67
|
- LICENSE.txt
|
@@ -91,8 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
91
92
|
- !ruby/object:Gem::Version
|
92
93
|
version: '0'
|
93
94
|
requirements: []
|
94
|
-
|
95
|
-
rubygems_version: 2.7.6
|
95
|
+
rubygems_version: 3.5.9
|
96
96
|
signing_key:
|
97
97
|
specification_version: 4
|
98
98
|
summary: rake notes task for non-Rails' projects
|