spreadsheet 1.1.8 → 1.1.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -1
- data/Gemfile.lock +5 -5
- data/bin/xlsopcodes +14 -13
- data/lib/spreadsheet.rb +1 -1
- data/lib/spreadsheet/excel/reader.rb +3 -2
- data/spreadsheet.gemspec +1 -2
- data/test/integration.rb +7 -7
- metadata +12 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bd771f6375c227ea8e847dd9baa0b8c594ee094b
|
4
|
+
data.tar.gz: d9ddedd561cfd67ab9784326aaad2bb0fd5877f7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: faf0102464aa6c38ed4c62052777e2acfdd2d463764a4d20a1aa51f7de3937685dc242f202e267a4e26ea52c9eb37b9cacc0a53e394323a16391ecce3da0e0fe
|
7
|
+
data.tar.gz: cdfa1580f3f6d47adb8bbe70c9d505660cf213b5d632526455de14d76c4ba5041e56aae2b755e3f5781a3464bc709b698fe44f46ef686a5b34612272467fa291
|
data/.travis.yml
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,12 +1,12 @@
|
|
1
1
|
GEM
|
2
2
|
remote: https://rubygems.org/
|
3
3
|
specs:
|
4
|
-
hoe (3.
|
5
|
-
rake (>= 0.8, <
|
4
|
+
hoe (3.17.1)
|
5
|
+
rake (>= 0.8, < 13.0)
|
6
6
|
minitest (5.8.2)
|
7
7
|
power_assert (0.2.4)
|
8
|
-
rake (10.
|
9
|
-
ruby-ole (1.2.
|
8
|
+
rake (10.5.0)
|
9
|
+
ruby-ole (1.2.12.1)
|
10
10
|
test-unit (3.1.5)
|
11
11
|
power_assert
|
12
12
|
|
@@ -20,4 +20,4 @@ DEPENDENCIES
|
|
20
20
|
test-unit
|
21
21
|
|
22
22
|
BUNDLED WITH
|
23
|
-
1.
|
23
|
+
1.17.2
|
data/bin/xlsopcodes
CHANGED
@@ -1,17 +1,18 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# frozen_string_literal: true
|
3
|
-
#
|
4
|
-
# This file was generated by Bundler.
|
5
|
-
#
|
6
|
-
# The application 'xlsopcodes' is installed as part of a gem, and
|
7
|
-
# this file is here to facilitate running it.
|
8
|
-
#
|
9
2
|
|
10
|
-
require
|
11
|
-
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
|
12
|
-
Pathname.new(__FILE__).realpath)
|
3
|
+
require 'spreadsheet'
|
13
4
|
|
14
|
-
|
15
|
-
require "bundler/setup"
|
5
|
+
source, target = ARGV
|
16
6
|
|
17
|
-
|
7
|
+
if source.nil?
|
8
|
+
puts "Usage: #{$0} <source> [<target>]"
|
9
|
+
exit -1
|
10
|
+
end
|
11
|
+
|
12
|
+
target = target ? File.open(target, 'w') : STDOUT
|
13
|
+
|
14
|
+
reader = Spreadsheet::Excel::Reader.new :print_opcodes => target
|
15
|
+
reader.setup File.open(source)
|
16
|
+
|
17
|
+
while tuple = reader.get_next_chunk
|
18
|
+
end
|
data/lib/spreadsheet.rb
CHANGED
@@ -399,10 +399,10 @@ class Reader
|
|
399
399
|
end
|
400
400
|
formula.value = value
|
401
401
|
elsif rtype == 0
|
402
|
-
pos, op,
|
402
|
+
pos, op, _len, work = get_next_chunk
|
403
403
|
if op == :sharedfmla
|
404
404
|
## TODO: formula-support in 0.8.0
|
405
|
-
pos, op,
|
405
|
+
pos, op, _len, work = get_next_chunk
|
406
406
|
end
|
407
407
|
if op == :string
|
408
408
|
formula.value = client read_string(work, 2), @workbook.encoding
|
@@ -852,6 +852,7 @@ class Reader
|
|
852
852
|
@detected_rows = {}
|
853
853
|
@noteObjList = []
|
854
854
|
@noteList = []
|
855
|
+
@noteObject = nil
|
855
856
|
previous = nil
|
856
857
|
while tuple = get_next_chunk
|
857
858
|
pos, op, len, work = tuple
|
data/spreadsheet.gemspec
CHANGED
@@ -3,7 +3,7 @@ lib = File.expand_path('../lib', __FILE__)
|
|
3
3
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
4
|
require 'spreadsheet'
|
5
5
|
|
6
|
-
|
6
|
+
Gem::Specification.new do |spec|
|
7
7
|
spec.name = "spreadsheet"
|
8
8
|
spec.version = Spreadsheet::VERSION
|
9
9
|
spec.homepage = "https://github.com/zdavatz/spreadsheet"
|
@@ -22,4 +22,3 @@ spec = Gem::Specification.new do |spec|
|
|
22
22
|
|
23
23
|
spec.homepage = 'https://github.com/zdavatz/spreadsheet/'
|
24
24
|
end
|
25
|
-
|
data/test/integration.rb
CHANGED
@@ -70,7 +70,7 @@ module Spreadsheet
|
|
70
70
|
def test_missing_format
|
71
71
|
path = File.join @data, 'test_missing_format.xls'
|
72
72
|
assert_nothing_thrown do
|
73
|
-
|
73
|
+
Spreadsheet.open(path, "rb")
|
74
74
|
end
|
75
75
|
end
|
76
76
|
def test_version_excel97__excel2010__utf16
|
@@ -749,7 +749,7 @@ module Spreadsheet
|
|
749
749
|
sheet1 = book.create_worksheet
|
750
750
|
str1 = 'My Shared String'
|
751
751
|
str2 = 'Another Shared String'
|
752
|
-
assert_equal 1, (str1.size + str2.size) % 2,
|
752
|
+
assert_equal 1, (str1.size + str2.size) % 2,
|
753
753
|
"str3 should start at an odd offset to test splitting of wide strings"
|
754
754
|
str3 = '–––––––––– ' * 1000
|
755
755
|
str4 = '1234567890 ' * 1000
|
@@ -1211,8 +1211,8 @@ module Spreadsheet
|
|
1211
1211
|
book = Spreadsheet::Workbook.new
|
1212
1212
|
sheet = book.create_worksheet
|
1213
1213
|
(0..200).each { |i| sheet.row(i).push "ëçáéíóú" }
|
1214
|
-
assert_nothing_raised do
|
1215
|
-
book.write StringIO.new("", "w+")
|
1214
|
+
assert_nothing_raised do
|
1215
|
+
book.write StringIO.new("", "w+")
|
1216
1216
|
end
|
1217
1217
|
end
|
1218
1218
|
|
@@ -1257,7 +1257,7 @@ module Spreadsheet
|
|
1257
1257
|
str1 = "Frozen String.".freeze
|
1258
1258
|
sheet1[0,0] = str1
|
1259
1259
|
sheet1.row(0).push str1
|
1260
|
-
assert_nothing_raised do
|
1260
|
+
assert_nothing_raised do
|
1261
1261
|
book.write path
|
1262
1262
|
end
|
1263
1263
|
end
|
@@ -1290,7 +1290,7 @@ module Spreadsheet
|
|
1290
1290
|
sheet1 = book.create_worksheet
|
1291
1291
|
(sheet1.row(0).format 0).border = :hair
|
1292
1292
|
(sheet1.row(0).format 0).border_color = :brown
|
1293
|
-
assert_nothing_raised do
|
1293
|
+
assert_nothing_raised do
|
1294
1294
|
book.write path
|
1295
1295
|
end
|
1296
1296
|
book2 = Spreadsheet.open path
|
@@ -1391,7 +1391,7 @@ module Spreadsheet
|
|
1391
1391
|
path = File.join @var, 'test_write_worksheet_visibility.xls'
|
1392
1392
|
sheet1 = book.create_worksheet
|
1393
1393
|
sheet1.visibility = :hidden
|
1394
|
-
|
1394
|
+
_sheet2 = book.create_worksheet
|
1395
1395
|
assert_nothing_raised do
|
1396
1396
|
book.write path
|
1397
1397
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: spreadsheet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Hannes F. Wyss, Masaomi Hatakeyama, Zeno R.R. Davatz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-01-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ruby-ole
|
@@ -28,30 +28,36 @@ dependencies:
|
|
28
28
|
name: rdoc
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '4.0'
|
34
|
+
- - "<"
|
35
|
+
- !ruby/object:Gem::Version
|
36
|
+
version: '7'
|
34
37
|
type: :development
|
35
38
|
prerelease: false
|
36
39
|
version_requirements: !ruby/object:Gem::Requirement
|
37
40
|
requirements:
|
38
|
-
- - "
|
41
|
+
- - ">="
|
39
42
|
- !ruby/object:Gem::Version
|
40
43
|
version: '4.0'
|
44
|
+
- - "<"
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: '7'
|
41
47
|
- !ruby/object:Gem::Dependency
|
42
48
|
name: hoe
|
43
49
|
requirement: !ruby/object:Gem::Requirement
|
44
50
|
requirements:
|
45
51
|
- - "~>"
|
46
52
|
- !ruby/object:Gem::Version
|
47
|
-
version: '3.
|
53
|
+
version: '3.17'
|
48
54
|
type: :development
|
49
55
|
prerelease: false
|
50
56
|
version_requirements: !ruby/object:Gem::Requirement
|
51
57
|
requirements:
|
52
58
|
- - "~>"
|
53
59
|
- !ruby/object:Gem::Version
|
54
|
-
version: '3.
|
60
|
+
version: '3.17'
|
55
61
|
description: |-
|
56
62
|
The Spreadsheet Library is designed to read and write Spreadsheet Documents.
|
57
63
|
As of version 0.6.0, only Microsoft Excel compatible spreadsheets are
|