fixme 3.1.1 → 4.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +7 -0
- data/lib/fixme.rb +7 -1
- data/lib/fixme/version.rb +1 -1
- data/spec/fixme_spec.rb +6 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 542218a87018613a2dc76f20bcdd28b66f40ea6a
|
4
|
+
data.tar.gz: ed4c8ed714fa465784188e8378aaad038ef06c41
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: deb1c1a6d45e97291628ed1ad53b3ad590a0f7bbc4c39cba97a62dc7e4c4d65806bbfa509f262a1c9045f42b5a0bce0257852b37fe704d17c73e6b592d22280e
|
7
|
+
data.tar.gz: 52c1ed22af9e8a1b5b7b1c0ea8b62ba090a6b72f7fffac5f6d8d99fd511abb3bddef0b667b5c742968aca0415c9d6f8e5d666db6e4929d23ffbb3d486ad42801
|
data/README.md
CHANGED
@@ -84,6 +84,13 @@ rake # Run tests.
|
|
84
84
|
```
|
85
85
|
|
86
86
|
|
87
|
+
## Also see
|
88
|
+
|
89
|
+
* [do_by](https://github.com/andyw8/do_by)
|
90
|
+
* [fixme-elixir](https://github.com/henrik/fixme-elixir)
|
91
|
+
* [fixme-js](https://github.com/markogresak/fixme-js)
|
92
|
+
|
93
|
+
|
87
94
|
## Contributors
|
88
95
|
|
89
96
|
* [Henrik Trotzig](https://www.causes.com/henric)
|
data/lib/fixme.rb
CHANGED
@@ -75,7 +75,13 @@ module Fixme
|
|
75
75
|
end
|
76
76
|
|
77
77
|
def parse
|
78
|
-
|
78
|
+
match = @date_and_message.match(/\A(\d\d\d\d-\d\d?-\d\d?): (.+)\z/)
|
79
|
+
|
80
|
+
unless match
|
81
|
+
raise %{FIXME does not follow the "2015-01-01: Foo" format: #{@date_and_message.inspect}}
|
82
|
+
end
|
83
|
+
|
84
|
+
raw_date, message = match.captures
|
79
85
|
[ Date.parse(raw_date), message ]
|
80
86
|
end
|
81
87
|
end
|
data/lib/fixme/version.rb
CHANGED
data/spec/fixme_spec.rb
CHANGED
@@ -41,6 +41,12 @@ describe Fixme, "#FIXME" do
|
|
41
41
|
}.to raise_error("Fix by 2013-12-31: Remove this: and this.")
|
42
42
|
end
|
43
43
|
|
44
|
+
it "complains if the desired format is not adhered to" do
|
45
|
+
expect {
|
46
|
+
FIXME "9999-01-01, Learn to: type"
|
47
|
+
}.to raise_error(%{FIXME does not follow the "2015-01-01: Foo" format: "9999-01-01, Learn to: type"})
|
48
|
+
end
|
49
|
+
|
44
50
|
it "is available everywhere" do
|
45
51
|
expect {
|
46
52
|
"some random object".instance_eval do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fixme
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 4.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Henrik Nyh
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-11-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|