remote_table 0.2.4 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/remote_table/file.rb +3 -3
- data/remote_table.gemspec +1 -1
- metadata +1 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.5
|
data/lib/remote_table/file.rb
CHANGED
@@ -25,7 +25,7 @@ class RemoteTable
|
|
25
25
|
class << self
|
26
26
|
# http://santanatechnotes.blogspot.com/2005/12/matching-iso-8859-1-strings-with-ruby.html
|
27
27
|
def convert_to_utf8(str, encoding)
|
28
|
-
if encoding == 'UTF-8'
|
28
|
+
if encoding == 'UTF-8' or encoding == 'UTF8'
|
29
29
|
str.toutf8 # just in case
|
30
30
|
else
|
31
31
|
@_iconv ||= Hash.new
|
@@ -73,8 +73,8 @@ class RemoteTable
|
|
73
73
|
end
|
74
74
|
|
75
75
|
def convert_file_to_utf8!
|
76
|
-
return if encoding == '
|
77
|
-
`iconv -c -f #{encoding} -t
|
76
|
+
return if encoding == 'UTF-8' or encoding == 'UTF8'
|
77
|
+
`iconv -c -f #{encoding} -t UTF-8 #{path} > #{path}.tmp`
|
78
78
|
FileUtils.mv "#{path}.tmp", path
|
79
79
|
end
|
80
80
|
|
data/remote_table.gemspec
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{remote_table}
|
8
|
-
s.version = "0.2.
|
8
|
+
s.version = "0.2.5"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Seamus Abshere", "Andy Rossmeissl"]
|