general 2.0.3 → 2.0.4

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
  SHA1:
3
- metadata.gz: f610cd0c2d52fe794bdfe47dce873c4aa170818e
4
- data.tar.gz: 8233a86e36c631edf9d030e7017c7177781013a2
3
+ metadata.gz: fe5d95a7df6e150f1f8e069f32441cd431ce67a7
4
+ data.tar.gz: 6b03033b692bcb99b057f840e85d1be6769d9d84
5
5
  SHA512:
6
- metadata.gz: e283ae5ffec30b14e89410034c1aef4a7a902563db1459d26cccfafbc9cf244aa99610891afb859e1cfad22e2e4e7b48f36ebb0414574ce5cdb98b242eca9d89
7
- data.tar.gz: dcb1a5a856a29e2acbb3dee59490d54b6d88bcfb346089129926ba7b9b19ab59506fb2763aaefb5d5cf4bf2b528196f1a754e9a6e56957fd36dbdc228f64916c
6
+ metadata.gz: 5538c80236bd37ec2b593a40bb91ae9bce7ddc7e884c1c90320ce3fcf2859a9bd40a282ce6d64d886727e7d81a42ca4dc45304d2559836da8c9b9b1eb0ab1c3c
7
+ data.tar.gz: 50a026344b8aaca7df99dbfbb4527499aa0f40a6395746a081da43a7675e915f5ba96470d71d9d81049a5afdb98999eb641eee41c06d29abf0bae7b867184d19
@@ -28,6 +28,6 @@ module General
28
28
  # Created: 1 - 30 - 2017
29
29
  class GPretext < GPrePartial
30
30
  # Regular expression matches GPretext
31
- REGEX = /\A(?<text>.+?)(?=@@|\z)/m
31
+ REGEX = /\A(?<text>.+?)(?=(@@|\z))/m
32
32
  end
33
33
  end
@@ -28,6 +28,6 @@ module General
28
28
  # Created: 1 - 30 - 2017
29
29
  class GYield < GPrePartial
30
30
  # Regular expression matches GYield
31
- REGEX = /\A@@yield\r?\n/
31
+ REGEX = /\A@@yield((\r?\n)|\z)/
32
32
  end
33
33
  end
@@ -61,7 +61,7 @@ module General
61
61
  end
62
62
 
63
63
  # Find an extend
64
- extindex = preparts.index{ |prepart| prepart.is_a? General::GExtend }
64
+ extindex = preparts.index { |prepart| prepart.is_a? General::GExtend }
65
65
 
66
66
  # Run extend algorithm (throw error if extend is found elsewhere)
67
67
  if extindex == 0
@@ -0,0 +1,5 @@
1
+ require_relative "general"
2
+
3
+ general = General::GIO.load "source.general"
4
+ puts
5
+ puts general.instance_variable_get(:@partials).collect(&:inspect)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: general
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.3
4
+ version: 2.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anshul Kharbanda
@@ -25,8 +25,8 @@ dependencies:
25
25
  - !ruby/object:Gem::Version
26
26
  version: '3.4'
27
27
  description: General is a simple templating system in ruby that allows you to create
28
- templates from bothpure strings and files (with the extension .general), as well
29
- as create new strings and fileswith these created objects. For more information,
28
+ templates from both pure strings and files (with the extension .general), as well
29
+ as create new strings and files with these created objects. For more information,
30
30
  visit the homepage
31
31
  email: akanshul97@gmail.com
32
32
  executables: []
@@ -84,6 +84,7 @@ files:
84
84
  - lib/gtemplates/gmeta.rb
85
85
  - lib/gtemplates/gtemplate.rb
86
86
  - lib/gtemplates/gtimeformat.rb
87
+ - lib/test.rb
87
88
  - spec/gdothash_spec.rb
88
89
  - spec/goperations_spec.rb
89
90
  - spec/gpartial_garrayplaceholder_spec.rb