tidtools 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +4 -0
- data/bin/tidgrep +1 -1
- data/lib/tidgrep/cli.rb +13 -5
- data/lib/tidtools.rb +1 -1
- data/script/console +0 -0
- data/script/destroy +0 -0
- data/script/generate +0 -0
- metadata +17 -36
data/History.txt
CHANGED
data/bin/tidgrep
CHANGED
data/lib/tidgrep/cli.rb
CHANGED
@@ -31,7 +31,7 @@ module Tidgrep
|
|
31
31
|
|
32
32
|
@content_regexps = []
|
33
33
|
keywords.each do |keyword|
|
34
|
-
@content_regexps << Regexp.new(
|
34
|
+
@content_regexps << Regexp.new(kcode2utf(keyword), @regexp_option)
|
35
35
|
end
|
36
36
|
end
|
37
37
|
|
@@ -47,20 +47,28 @@ module Tidgrep
|
|
47
47
|
return true
|
48
48
|
end
|
49
49
|
|
50
|
-
def
|
50
|
+
def kcode2utf(str)
|
51
51
|
if (@kcode != Kconv::UTF8)
|
52
|
-
str.kconv(
|
52
|
+
str.kconv(Kconv::UTF8, @kcode)
|
53
|
+
else
|
54
|
+
str
|
55
|
+
end
|
56
|
+
end
|
57
|
+
|
58
|
+
def utf2kcode(str)
|
59
|
+
if (@kcode != Kconv::UTF8)
|
60
|
+
str.kconv(@kcode, Kconv::UTF8)
|
53
61
|
else
|
54
62
|
str
|
55
63
|
end
|
56
64
|
end
|
57
65
|
|
58
66
|
def print(msg)
|
59
|
-
@stdout.print
|
67
|
+
@stdout.print utf2kcode(msg)
|
60
68
|
end
|
61
69
|
|
62
70
|
def puts(msg)
|
63
|
-
@stdout.puts
|
71
|
+
@stdout.puts utf2kcode(msg)
|
64
72
|
end
|
65
73
|
|
66
74
|
def match_line
|
data/lib/tidtools.rb
CHANGED
data/script/console
CHANGED
File without changes
|
data/script/destroy
CHANGED
File without changes
|
data/script/generate
CHANGED
File without changes
|
metadata
CHANGED
@@ -1,12 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tidtools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
segments:
|
6
|
-
- 0
|
7
|
-
- 0
|
8
|
-
- 5
|
9
|
-
version: 0.0.5
|
4
|
+
version: 0.0.6
|
10
5
|
platform: ruby
|
11
6
|
authors:
|
12
7
|
- ongaeshi
|
@@ -14,51 +9,39 @@ autorequire:
|
|
14
9
|
bindir: bin
|
15
10
|
cert_chain: []
|
16
11
|
|
17
|
-
date: 2010-04-
|
12
|
+
date: 2010-04-29 00:00:00 +09:00
|
18
13
|
default_executable:
|
19
14
|
dependencies:
|
20
15
|
- !ruby/object:Gem::Dependency
|
21
16
|
name: hpricot
|
22
|
-
|
23
|
-
|
17
|
+
type: :runtime
|
18
|
+
version_requirement:
|
19
|
+
version_requirements: !ruby/object:Gem::Requirement
|
24
20
|
requirements:
|
25
21
|
- - ">="
|
26
22
|
- !ruby/object:Gem::Version
|
27
|
-
segments:
|
28
|
-
- 0
|
29
|
-
- 8
|
30
|
-
- 2
|
31
23
|
version: 0.8.2
|
32
|
-
|
33
|
-
version_requirements: *id001
|
24
|
+
version:
|
34
25
|
- !ruby/object:Gem::Dependency
|
35
26
|
name: rubyforge
|
36
|
-
|
37
|
-
|
27
|
+
type: :development
|
28
|
+
version_requirement:
|
29
|
+
version_requirements: !ruby/object:Gem::Requirement
|
38
30
|
requirements:
|
39
31
|
- - ">="
|
40
32
|
- !ruby/object:Gem::Version
|
41
|
-
segments:
|
42
|
-
- 2
|
43
|
-
- 0
|
44
|
-
- 4
|
45
33
|
version: 2.0.4
|
46
|
-
|
47
|
-
version_requirements: *id002
|
34
|
+
version:
|
48
35
|
- !ruby/object:Gem::Dependency
|
49
36
|
name: hoe
|
50
|
-
|
51
|
-
|
37
|
+
type: :development
|
38
|
+
version_requirement:
|
39
|
+
version_requirements: !ruby/object:Gem::Requirement
|
52
40
|
requirements:
|
53
41
|
- - ">="
|
54
42
|
- !ruby/object:Gem::Version
|
55
|
-
segments:
|
56
|
-
- 2
|
57
|
-
- 6
|
58
|
-
- 0
|
59
43
|
version: 2.6.0
|
60
|
-
|
61
|
-
version_requirements: *id003
|
44
|
+
version:
|
62
45
|
description: FIX (describe your package)
|
63
46
|
email:
|
64
47
|
- ongaeshi@example.com
|
@@ -105,20 +88,18 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
105
88
|
requirements:
|
106
89
|
- - ">="
|
107
90
|
- !ruby/object:Gem::Version
|
108
|
-
segments:
|
109
|
-
- 0
|
110
91
|
version: "0"
|
92
|
+
version:
|
111
93
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
112
94
|
requirements:
|
113
95
|
- - ">="
|
114
96
|
- !ruby/object:Gem::Version
|
115
|
-
segments:
|
116
|
-
- 0
|
117
97
|
version: "0"
|
98
|
+
version:
|
118
99
|
requirements: []
|
119
100
|
|
120
101
|
rubyforge_project: tidtools
|
121
|
-
rubygems_version: 1.3.
|
102
|
+
rubygems_version: 1.3.5
|
122
103
|
signing_key:
|
123
104
|
specification_version: 3
|
124
105
|
summary: FIX (describe your package)
|