butler-mainframe 0.7.5 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -1
- data/lib/mainframe/emulators/pcomm.rb +1 -0
- data/lib/mainframe/host_base.rb +6 -9
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 905103b0a75c74a621416783ca7640547705ffc8
|
4
|
+
data.tar.gz: 96016897c77be9676a6fe2de3bd6871e004a6ce7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1c859409e7690859468559bfa7bd5f25bdb884d0c0f28305e45bf953df01e508b86bd4fe3198f1f6d8c4f51439ec67c102fb8169a48c0ecf28aa681a51395661
|
7
|
+
data.tar.gz: 28ccc959ee5931b50d123e2d173be2ba6f898c136f4ccb6c5c068a0b5219622801b366ad16058c26fdf78347979e89c677eb6171ef6506582a79fd4cfc959ca5
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,13 @@
|
|
1
|
+
0.8.0 [☰](https://github.com/marcomd/butler-mainframe/compare/v0.7.5...v0.8.0) May 3th, 2016
|
2
|
+
------------------------------
|
3
|
+
* PComm emulator: the write param 'clean_chars_before_writing' didn't work
|
4
|
+
* Improved write with params clean_chars_before_writing:
|
5
|
+
* now switch off erase_before_writing because there might be a conflict
|
6
|
+
* now switch off check protect param which use SendKey and it could provide an unexpected result
|
7
|
+
|
1
8
|
0.7.5 [☰](https://github.com/marcomd/butler-mainframe/compare/v0.7.4...v0.7.5) April 19th, 2016
|
2
9
|
------------------------------
|
3
|
-
* Fixed a bug (Stack level too deep) on the write command when was passed the parameter :
|
10
|
+
* Fixed a bug (Stack level too deep) on the write command when was passed the parameter :clean_chars_before_writing
|
4
11
|
|
5
12
|
0.7.4 [☰](https://github.com/marcomd/butler-mainframe/compare/v0.7.3...v0.7.4) April 13th, 2016
|
6
13
|
------------------------------
|
data/lib/mainframe/host_base.rb
CHANGED
@@ -112,7 +112,7 @@ module ButlerMainframe
|
|
112
112
|
# :check => true,
|
113
113
|
# :raise_error_on_check => true,
|
114
114
|
# :sensible_data => nil,
|
115
|
-
# :clean_chars_before_writing => nil, # clean x chars before writing a value
|
115
|
+
# :clean_chars_before_writing => nil, # clean x chars before writing a value, it switch off erase_before_writing
|
116
116
|
# :erase_before_writing => nil # execute an erase until end of field before write a text
|
117
117
|
def write text, options={}
|
118
118
|
options = show_deprecated_param(:erase_field_first, :erase_before_writing, options) if options[:erase_field_first]
|
@@ -127,6 +127,7 @@ module ButlerMainframe
|
|
127
127
|
:clean_chars_before_writing => nil,
|
128
128
|
:erase_before_writing => @erase_before_writing
|
129
129
|
}.merge(options)
|
130
|
+
options[:erase_before_writing] = false if options[:clean_chars_before_writing]
|
130
131
|
|
131
132
|
y = options[:y]
|
132
133
|
x = options[:x]
|
@@ -267,20 +268,16 @@ module ButlerMainframe
|
|
267
268
|
:check => true,
|
268
269
|
:raise_error_on_check => true,
|
269
270
|
:sensible_data => nil,
|
270
|
-
:
|
271
|
+
:clean_chars_before_writing => nil,
|
271
272
|
:erase_before_writing => nil
|
272
273
|
}.merge(options)
|
273
274
|
raise "Impossible to write beyond row #{MAX_TERMINAL_ROWS}" if y > MAX_TERMINAL_ROWS
|
274
275
|
raise "Impossible to write beyond column #{MAX_TERMINAL_COLUMNS}" if x > MAX_TERMINAL_COLUMNS
|
275
276
|
raise "Impossible to write a null value" unless text
|
276
277
|
|
277
|
-
if options[:
|
278
|
-
puts "write_text_on_map: Clean #{options[:
|
279
|
-
|
280
|
-
unless bol_cleaned
|
281
|
-
puts "write_text_on_map: EHI! Impossible to clean the area specified" if @debug
|
282
|
-
return false
|
283
|
-
end
|
278
|
+
if options[:clean_chars_before_writing] && options[:clean_chars_before_writing].to_i > 0
|
279
|
+
puts "write_text_on_map: Clean #{options[:clean_chars_before_writing]} char#{options[:clean_chars_before_writing] == 1 ? '' : 's'} y:#{y} x:#{x}" if @debug
|
280
|
+
sub_write_text(" " * options[:clean_chars_before_writing], y, x, :check_protect => false)
|
284
281
|
end
|
285
282
|
|
286
283
|
if options[:erase_before_writing]
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: butler-mainframe
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marco Mastrodonato
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-05-03 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: This gem provides a virtual butler which can perform your custom tasks
|
14
14
|
on a 3270 emulator. Choose your emulator, configure your task and discover a new
|