robust_excel_ole 1.19.1 → 1.19.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/jreo.bat +4 -0
- data/bin/reo +19 -2
- data/bin/reo.bat +4 -0
- data/lib/reo_console.rb +1 -1
- data/lib/robust_excel_ole/excel.rb +0 -5
- data/lib/robust_excel_ole/general.rb +13 -0
- data/lib/robust_excel_ole/version.rb +1 -1
- data/spec/data/more_data/workbook.xls +0 -0
- metadata +6 -4
- data/bin/jreo +0 -74
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6ba39d6930c0c0ba0391bd5a75bcbee0d5cfc33e8459ea0f45b383988a8b1621
|
4
|
+
data.tar.gz: dc710437e2290d5caa21866349fe85d05752c7c5d2649010f150dce588f9ab90
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7b227106e853e8395300f9c76886e7cf0d93e55ca52902eed745f0ca23874ff9af0c34214362c07da448c29b3e68a0817684cdc75b911b3d33711664915b1f4f
|
7
|
+
data.tar.gz: aee9dac89259c407dd9b8f8ab5035af84bdc3c5561b40be6075af2602f590adcad0e45f945ff72ed5a4bf229a9b29c75e3cc16bf3d961f3d2ad669ce8a2e054c
|
data/bin/jreo.bat
ADDED
data/bin/reo
CHANGED
@@ -1,4 +1,21 @@
|
|
1
|
-
|
1
|
+
require 'pry'
|
2
|
+
require 'robust_excel_ole'
|
3
|
+
include REO
|
4
|
+
# include RobustExcelOle
|
5
|
+
include General
|
2
6
|
|
3
|
-
|
7
|
+
puts 'REO console started'
|
8
|
+
puts
|
4
9
|
|
10
|
+
|
11
|
+
# some pry configuration
|
12
|
+
Pry.config.windows_console_warning = false
|
13
|
+
Pry.config.history.should_save = true
|
14
|
+
#Pry.editor = 'notepad' # 'subl', 'vi'
|
15
|
+
#Pry.config.prompt =
|
16
|
+
# [
|
17
|
+
# ->(_obj, _nest_level, _) { ">> " },
|
18
|
+
# ->(*) { " " }
|
19
|
+
# ]
|
20
|
+
|
21
|
+
pry
|
data/bin/reo.bat
ADDED
data/lib/reo_console.rb
CHANGED
@@ -95,6 +95,8 @@ end
|
|
95
95
|
|
96
96
|
# @private
|
97
97
|
class WIN32OLE
|
98
|
+
|
99
|
+
include Enumerable
|
98
100
|
|
99
101
|
# type-lifting WIN32OLE objects to RobustExcelOle objects
|
100
102
|
def to_reo
|
@@ -121,6 +123,17 @@ class WIN32OLE
|
|
121
123
|
end
|
122
124
|
raise TypeREOError, "given object cannot be type-lifted to a RobustExcelOle object"
|
123
125
|
end
|
126
|
+
|
127
|
+
alias method_missing_before_implicit_typelift method_missing
|
128
|
+
def xx_method_missing(name, *args, &blk)
|
129
|
+
begin
|
130
|
+
reo_obj = self.to_reo
|
131
|
+
rescue
|
132
|
+
puts "$!.message: #{$!.message}"
|
133
|
+
method_missing_before_implicit_typelift(name, *args, &blk)
|
134
|
+
end
|
135
|
+
reo_obj.send(name, *args, &blk)
|
136
|
+
end
|
124
137
|
end
|
125
138
|
|
126
139
|
# @private
|
Binary file
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: robust_excel_ole
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.19.
|
4
|
+
version: 1.19.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- traths
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-07-
|
11
|
+
date: 2020-07-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -34,8 +34,9 @@ description: "RobustExcelOle helps controlling Excel. \n This
|
|
34
34
|
email:
|
35
35
|
- Thomas.Raths@gmx.net
|
36
36
|
executables:
|
37
|
-
- jreo
|
37
|
+
- jreo.bat
|
38
38
|
- reo
|
39
|
+
- reo.bat
|
39
40
|
extensions: []
|
40
41
|
extra_rdoc_files:
|
41
42
|
- README.rdoc
|
@@ -64,8 +65,9 @@ files:
|
|
64
65
|
- benchmarking/sample_excel_files/xlsx_500_rows.xlsx
|
65
66
|
- benchmarking/simple_xlsx_reader_example.rb
|
66
67
|
- benchmarking/spreadsheet_example.rb
|
67
|
-
- bin/jreo
|
68
|
+
- bin/jreo.bat
|
68
69
|
- bin/reo
|
70
|
+
- bin/reo.bat
|
69
71
|
- docs/README_excel.rdoc
|
70
72
|
- docs/README_open.rdoc
|
71
73
|
- docs/README_ranges.rdoc
|
data/bin/jreo
DELETED
@@ -1,74 +0,0 @@
|
|
1
|
-
#!/usr/bin/env jruby
|
2
|
-
# -*- mode: jruby -*-
|
3
|
-
|
4
|
-
require 'robust_excel_ole'
|
5
|
-
include REO
|
6
|
-
# include RobustExcelOle
|
7
|
-
include General
|
8
|
-
|
9
|
-
require 'irb'
|
10
|
-
require 'irb/completion'
|
11
|
-
require 'irb/ext/save-history'
|
12
|
-
#gem 'jruby-readline'
|
13
|
-
|
14
|
-
ARGV.concat ['--readline',
|
15
|
-
'--prompt-mode',
|
16
|
-
'simple']
|
17
|
-
# '-rjruby-readline']
|
18
|
-
|
19
|
-
#IRB.conf[:PROMPT_MODE] = :SIMPLE
|
20
|
-
#IRB.conf[:USE_READLINE] = true
|
21
|
-
#IRB.conf[:AUTO_INDENT] = true
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
# 250 entries in the list
|
27
|
-
IRB.conf[:SAVE_HISTORY] = 250
|
28
|
-
|
29
|
-
# Store results in home directory with specified file name
|
30
|
-
# IRB.conf[:HISTORY_FILE] = "#{ENV['HOME']}/.irb-history"
|
31
|
-
#IRB.conf[:HISTORY_FILE] = "#{ENV['HOME']}/.irb-save-history"
|
32
|
-
|
33
|
-
IRB.conf[:HISTORY_FILE] = "#{ENV['HOME']}/.reo-history"
|
34
|
-
|
35
|
-
# @private
|
36
|
-
module Readline
|
37
|
-
module Hist
|
38
|
-
LOG = IRB.conf[:HISTORY_FILE]
|
39
|
-
# LOG = "#{ENV['HOME']}/.irb-history"
|
40
|
-
|
41
|
-
def self.write_log(line)
|
42
|
-
File.open(LOG, 'ab') do |f|
|
43
|
-
f << "#{line}
|
44
|
-
"
|
45
|
-
end
|
46
|
-
end
|
47
|
-
|
48
|
-
def self.start_session_log
|
49
|
-
timestamp = proc { Time.now.strftime('%Y-%m-%d, %H:%M:%S') }
|
50
|
-
# @private
|
51
|
-
class <<timestamp
|
52
|
-
alias_method :to_s, :call
|
53
|
-
end
|
54
|
-
write_log("###### session start: #{timestamp}")
|
55
|
-
at_exit { write_log("###### session stop: #{timestamp}") }
|
56
|
-
end
|
57
|
-
end
|
58
|
-
|
59
|
-
alias old_readline readline
|
60
|
-
def readline(*args)
|
61
|
-
ln = old_readline(*args)
|
62
|
-
begin
|
63
|
-
Hist.write_log(ln)
|
64
|
-
rescue StandardError
|
65
|
-
end
|
66
|
-
ln
|
67
|
-
end
|
68
|
-
end
|
69
|
-
|
70
|
-
Readline::Hist.start_session_log
|
71
|
-
puts 'JREO console started'
|
72
|
-
|
73
|
-
|
74
|
-
IRB.start
|