slim-mustache 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 562500bd8d243874a5d5e1a5ab40bb57eaf56ef9
4
- data.tar.gz: 57a5be165c197e98faa623d342dd695fe451759a
3
+ metadata.gz: 3387fd7e0528f20bba54d45e87f087a08f5af978
4
+ data.tar.gz: f292a898b0659d9e7c5cb77d52a6358baece7648
5
5
  SHA512:
6
- metadata.gz: b9a7402dbbffdcf453ac8d29670857fbccf74f7ac5a9b369f32873864991aac4c51e4bf3e3d2b8ff3a19abbdb00079a355c29d81e8f053368c927b14f605cc12
7
- data.tar.gz: cee9251a2e407a82cc0b5de0b1d0a1d9066e057116104ebca1bc103de8a1a373d86b3ba5ac1221ebe68e0b7896c9c7e6d4d4688415d99fba6be2f4dcb24c00d6
6
+ metadata.gz: 9b62aae14919d8029062cc668b9f7cd486fb9755b392a692f1906c174f817b08137df2391932650900c6827aa55db6a0d3eca175898ff6f0a38e50de3a87ecf2
7
+ data.tar.gz: d294ed6ecda3b5c593fcc1935f7177455952b4f974ebfac5fd058a020f246e06791fe4934804780fb5b60bc4e251f9aca22b5321a5f2c42e5cb798d3adda55ca
data/Rakefile CHANGED
@@ -21,7 +21,7 @@ Jeweler::Tasks.new do |gem|
21
21
  gem.description = %Q{use a ~tilde to generate \{\{mustache\}\} syntax}
22
22
  gem.email = "michelbenevento@yahoo.com"
23
23
  gem.authors = ["Michel Benevento"]
24
- gem.version = "1.0.1"
24
+ gem.version = "1.0.2"
25
25
  # dependencies defined in Gemfile
26
26
  end
27
27
  Jeweler::RubygemsDotOrgTasks.new
@@ -12,7 +12,7 @@ module Slim
12
12
  end
13
13
 
14
14
  def on_slim_interpolate(string)
15
- matches = string.scan(/([^~]*)~([!>])?(\((.*)\)|([^ ]*[\w}]))([^~]*)/)
15
+ matches = string.scan(/([^~]*)~([!>])?(\((.*)\)|([^ ]*[\w}])|\.)([^~]*)/)
16
16
  if matches.any?
17
17
  stack = [:multi]
18
18
  matches.each do |first, prefix, text, clean_text, _, last|
@@ -2,11 +2,11 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: slim-mustache 1.0.1 ruby lib
5
+ # stub: slim-mustache 1.0.2 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "slim-mustache"
9
- s.version = "1.0.1"
9
+ s.version = "1.0.2"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib"]
@@ -31,6 +31,13 @@ h2 some more ~foo
31
31
  assert_html '{{foo.bar}}. baz', source
32
32
  end
33
33
 
34
+ def test_single_dots
35
+ source = %q{
36
+ | foo ~. bar
37
+ }
38
+ assert_html 'foo {{.}} bar', source
39
+ end
40
+
34
41
  def test_dots_section
35
42
  source = %q{
36
43
  ~#if user.active
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: slim-mustache
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michel Benevento