smarter_csv 1.10.0 → 1.10.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f1d0b58acf0135b621e3182470674230ef73b48c829810e74fffa975fc318cf5
4
- data.tar.gz: ee404c5c485748d35cda36b8d249cb6813a3f80005182fe8c05feac1694aba57
3
+ metadata.gz: 6b214e402e999d37eb8fff613e0d87afe9084298ea0813447ca81aec33d7503a
4
+ data.tar.gz: 5344f4221d56ce53864bcd825c35d128cd998b1a54a2f60bed6f7e9d4d7c802f
5
5
  SHA512:
6
- metadata.gz: 4fee097fe2237f863510100155062da6815237260da5b15189f104f54596f7d5ff0479deb80596544e0bb1b9ba7b78126d2251798721e8d2f91e06b430950cd6
7
- data.tar.gz: c30562965452ef296b5e5aaf2a9a12887aa42d8e8396780b73b34f99a2386d232bf020578618fcbd65186fc864518c81a3e7555cae9b00a005322f3599e18c5a
6
+ metadata.gz: f05993e5a591b7b720dc2833d525ee2443d6fe00e6d0acdda2d237406296e16fddbe3959ff8df57f6d3bf64f95401f3d8b3b83d4a8a92ea8e9a7a8ba82cd57fe
7
+ data.tar.gz: 906a7b5ef793ed46d875a77d55471d568f6ac5adebcf2c121bf67ecdbbf150059eb0eeddec6a63a2d10cc6617ed2ba7359eeb6f627b25891a38ea4bdbdf37b83
data/CHANGELOG.md CHANGED
@@ -1,6 +1,9 @@
1
1
 
2
2
  # SmarterCSV 1.x Change Log
3
3
 
4
+ ## 1.10.1 (2024-01-07)
5
+ * fix incorrect warning about UTF-8 (issue #268, thanks hirowatari)
6
+
4
7
  ## 1.10.0 (2023-12-31) ⚡ BREAKING ⚡
5
8
 
6
9
  * BREAKING CHANGES:
data/CONTRIBUTORS.md CHANGED
@@ -51,3 +51,4 @@ A Big Thank you to everyone who filed issues, sent comments, and who contributed
51
51
  * [Rahul Chaudhary](https://github.com/rahulch95)
52
52
  * [Alessandro Fazzi](https://github.com/pioneerskies)
53
53
  * [JP Camara](https://github.com/jpcamara)
54
+ * [Hiro Watari](https://github.com/hirowatari)
@@ -22,7 +22,7 @@ module SmarterCSV
22
22
  begin
23
23
  fh = input.respond_to?(:readline) ? input : File.open(input, "r:#{options[:file_encoding]}")
24
24
 
25
- if @enforce_utf8 && (fh.respond_to?(:external_encoding) && fh.external_encoding != Encoding.find('UTF-8') || fh.respond_to?(:encoding) && fh.encoding != Encoding.find('UTF-8'))
25
+ if (options[:force_utf8] || options[:file_encoding] =~ /utf-8/i) && (fh.respond_to?(:external_encoding) && fh.external_encoding != Encoding.find('UTF-8') || fh.respond_to?(:encoding) && fh.encoding != Encoding.find('UTF-8'))
26
26
  puts 'WARNING: you are trying to process UTF-8 input, but did not open the input with "b:utf-8" option. See README file "NOTES about File Encodings".'
27
27
  end
28
28
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SmarterCSV
4
- VERSION = "1.10.0"
4
+ VERSION = "1.10.1"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: smarter_csv
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.10.0
4
+ version: 1.10.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tilo Sloboda
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-12-31 00:00:00.000000000 Z
11
+ date: 2024-01-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: awesome_print
@@ -151,7 +151,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
151
151
  - !ruby/object:Gem::Version
152
152
  version: '0'
153
153
  requirements: []
154
- rubygems_version: 3.5.3
154
+ rubygems_version: 3.2.3
155
155
  signing_key:
156
156
  specification_version: 4
157
157
  summary: Ruby Gem for smarter importing of CSV Files (and CSV-like files), with lots