gtdlint 0.2 → 0.3

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.
Files changed (6) hide show
  1. checksums.yaml +4 -4
  2. data/CONFIGURE.md +1 -1
  3. data/README.md +4 -12
  4. data/lib/gtdlint.rb +20 -18
  5. data/lib/version.rb +1 -1
  6. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a1da6f127afe0bb3c5653d0002fcb4efb770e692
4
- data.tar.gz: 1bbcb3d4702285a9ed6c95419c07a22ca664309f
3
+ metadata.gz: d591322656c0fe0cea4f051ca0176534cd6149f9
4
+ data.tar.gz: 5179179da2f3d4215093a646559b41d3bb6bd909
5
5
  SHA512:
6
- metadata.gz: ec57224fa746f02f709c1c8b07eb2060ef9edcf1233918cd3b0fbae32e8d08749107dc64a28fa54ff31c8b78361df80344d42ebe92c25731d3eff4de61e91eb9
7
- data.tar.gz: 47b3cf59340a52d8f4ce4500b9d15c1f062811663dc21e78acc3e61bca179774de8bcee06fef804638c246b393e40cd70459c2874f74cf746f267ac9127e79b0
6
+ metadata.gz: 9d83c3e1e4f2b240f06ad740fb9e836ceb50baa3229f169de2cfd3868ae108bf7f8f9146c1aecb41b0c4ec46cf3ef0d2d1214796fa0b61c7ac100111c860db6f
7
+ data.tar.gz: 3cf111bdfbe47896ece72539ba0b71c9c7d3e5ddfeea6bf931e553865b9ff2d133f5f182800b7ebc1801eda99a2310ae3f8ef77aa6bd8e0bfb32d170f080cf43
data/CONFIGURE.md CHANGED
@@ -47,6 +47,6 @@ Samples:
47
47
 
48
48
  # Built-in defaults
49
49
 
50
- * `gtd_pattern`: `"\'todo\\|to do\\|to-do\\|hack\'"`.
50
+ * `gtd_pattern`: `"\'todo\\|to do\\|to-do\\|pending\\|hack\'"`.
51
51
  * `before_lines`: `0`
52
52
  * `after_lines`: `0`
data/README.md CHANGED
@@ -13,18 +13,8 @@ https://rubygems.org/gems/gtdlint
13
13
  Gtdlint is a command line program for finding TODO tasks in a project, such as `// TODO` code comments. By default, gtdlint is case-insensitve, and looks for:
14
14
 
15
15
  * `todo`
16
- * `to do`
17
- * `to-do`
18
- * `TODO`
19
- * `TO DO`
20
- * `TO-DO`
21
- * `ToDo`
22
- * `To Do`
23
- * `To-Do`
16
+ * `pending`
24
17
  * `hack`
25
- * `Hack`
26
- * `HACK`
27
- * ...
28
18
 
29
19
  gtdlint can be customized with a `-p` command line flag and/or a `.gtdlintrc.yml` configuration file. For example, gtdlint can be configured to look for `pte`/`hack` in Spanish projects.
30
20
 
@@ -43,14 +33,16 @@ examples/hello.c:1:// TODO: Add copyright
43
33
  examples/hello.c:6: // TODO: Add proper line ending
44
34
  examples/hello.c:9: putc(10, stdout); // hack
45
35
  examples/spanish/phrases.txt:1:PTE: Agregar más frases.
36
+ examples/spec/int_spec.rb:3: pending('mathematical revolution')
46
37
 
47
38
  $ cat examples/hello.c | bin/gtdlint
48
39
  stdin:1:// TODO: Add copyright
49
40
  stdin:6: // TODO: Add proper line ending
50
41
  stdin:9: putc(10, stdout); // hack
51
42
 
52
- $ gtdlint -i .c examples/
43
+ $ gtdlint -i '\.c' examples/
53
44
  examples/spanish/phrases.txt:1:PTE: Agregar más frases.
45
+ examples/spec/int_spec.rb:3: pending('mathematical revolution')
54
46
 
55
47
  $ gtdlint -p pte examples/spanish/
56
48
  examples/spanish/phrases.txt:1:PTE: Agregar más frases.
data/lib/gtdlint.rb CHANGED
@@ -7,27 +7,27 @@ $stdout.sync = true
7
7
  require 'version'
8
8
 
9
9
  DEFAULT_IGNORES = %w(
10
- .hg/
11
- .svn/
12
- .git/
13
- .git
14
- .gtdlintignore
15
- .gtdlintrc.yml
10
+ \.hg/
11
+ \.svn/
12
+ \.git/
13
+ \.git
14
+ \.gtdlintignore
15
+ \.gtdlintrc\.yml
16
16
  node_modules/
17
- .vagrant/
17
+ \.vagrant/
18
18
  Gemfile.lock
19
- .exe
20
- .bin
21
- .png
22
- .jpg
23
- .jpeg
24
- .svg
25
- .min.js
26
- -min.js
19
+ \.exe
20
+ \.bin
21
+ \.png
22
+ \.jpg
23
+ \.jpeg
24
+ \.svg
25
+ \.min.js
26
+ -min\.js
27
27
  )
28
28
 
29
29
  # Grep format, case insensitive
30
- DEFAULT_GTD_PATTERN = "\'todo\\|to do\\|to-do\\|hack\'"
30
+ DEFAULT_GTD_PATTERN = "\'todo\\|to do\\|to-do\\|pending\\|hack\'"
31
31
 
32
32
  DEFAULT_LINES_BEFORE = 0
33
33
  DEFAULT_LINES_AFTER = 0
@@ -98,7 +98,8 @@ def self.check_stdin(configuration = DEFAULT_CONFIGURATION)
98
98
  -B #{lines_before} \
99
99
  -A #{lines_after} \
100
100
  -n \
101
- -i #{gtd_pattern} \
101
+ -i \
102
+ -w #{gtd_pattern} \
102
103
  \"#{filename}\"
103
104
  `
104
105
 
@@ -118,7 +119,8 @@ def self.check(filename, configuration = DEFAULT_CONFIGURATION)
118
119
  -B #{lines_before} \
119
120
  -A #{lines_after} \
120
121
  -n \
121
- -i #{gtd_pattern} \
122
+ -i \
123
+ -w #{gtd_pattern} \
122
124
  \"#{filename}\"
123
125
  `
124
126
 
data/lib/version.rb CHANGED
@@ -2,5 +2,5 @@
2
2
  # GTDLint
3
3
  #
4
4
  module GTDLint
5
- VERSION = '0.2'
5
+ VERSION = '0.3'
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gtdlint
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.2'
4
+ version: '0.3'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Pennebaker