livetext 0.8.83 → 0.8.84

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 236395813414f363d90340dc5e0977daee51ba47bc758d613ed3fa2b419e2cfd
4
- data.tar.gz: 70c2eab78b98933073b13c95c2b4855803573731ca151a4e07faaa618233f125
3
+ metadata.gz: 20830ef3a88634fa613b455047e28820be9f6a728b2490d2f4d7e93a2b711a55
4
+ data.tar.gz: fd041725cfe278c4c9517fcb7da6f7fc11602170a3b8cc435d0b79a35745d7d8
5
5
  SHA512:
6
- metadata.gz: 2017af970244166cdec4d15e08cf3e76fe86b1cef4f344386ff3023e78576dc6ddc245b49fe7f27f4645c67a19f154ca594758e83a21097a6c5322e2bf45a70c
7
- data.tar.gz: dd4d20cebb6f20e660898a03817987260d134a55b00885c97306f3e4f7c2c2caccdd6e3b5017b31326eeb8973a48cc27020e9508afbd5f2b4c2e11599a110ccd
6
+ metadata.gz: 285ba05a8ed1b0c683bbb11deee1259f1e7d2d98657936222c855ca5c1a72c8d5991cf8291442481266ba1156f9a9f84b34a8bab565aa67c09c227bb0d063dd8
7
+ data.tar.gz: 45eb8e3fb17596afd84f0ded7fe09c96a575c522c6419494a4ac43be162772317f06e79aff99d9d3206eefe15f8dfe94eaef1d7470e9c9327f2497ef3efef4e8
@@ -49,7 +49,7 @@ class FormatLine
49
49
  grab
50
50
  loop do
51
51
  case curr
52
- when Escape; go; add curr; grab
52
+ when Escape; grab; add curr; grab
53
53
  when "$"
54
54
  dollar
55
55
  when "*", "_", "`", "~"
@@ -75,7 +75,7 @@ class FormatLine
75
75
  x.grab
76
76
  loop do
77
77
  case x.curr
78
- when Escape; x.go; x.add x.curr; x.grab
78
+ when Escape; x.grab; x.add x.curr; x.grab
79
79
  when "$"
80
80
  x.dollar
81
81
  when LF, nil
@@ -1,5 +1,5 @@
1
1
  class Livetext
2
- VERSION = "0.8.83"
2
+ VERSION = "0.8.84"
3
3
  Path = File.expand_path(File.join(File.dirname(__FILE__)))
4
4
  end
5
5
 
@@ -45,7 +45,7 @@ module Livetext::Standard
45
45
  def #{funcname}(param)
46
46
  #{_body_text(true)}
47
47
  end
48
- EOS
48
+ EOS
49
49
  Livetext::Functions.class_eval func_def
50
50
  end
51
51
 
@@ -189,6 +189,25 @@ module Livetext::Standard
189
189
  _optional_blank_line
190
190
  end
191
191
 
192
+ def _seek(file)
193
+ if File.exist?(file)
194
+ return file
195
+ else
196
+ _seek("../#{file}")
197
+ end
198
+ rescue
199
+ return nil
200
+ end
201
+
202
+ def seek
203
+ # like include, but search upward as needed
204
+ file = @_args.first
205
+ file = _seek(file)
206
+ _error!(file, "No such include file '#{file}'") unless file
207
+ @parent.process_file(file)
208
+ _optional_blank_line
209
+ end
210
+
192
211
  def _include
193
212
  file = @_args.first
194
213
  _check_existence(file, "No such include file '#{file}'")
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: livetext
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.83
4
+ version: 0.8.84
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hal Fulton
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-05-13 00:00:00.000000000 Z
11
+ date: 2019-05-22 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A smart text processor extensible in Ruby
14
14
  email: rubyhacker@gmail.com