erubis_for_rails23 0.1

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.
@@ -0,0 +1,17 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in erubis_for_rails23.gemspec
4
+ gemspec
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2013 Bachue Zhou
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,29 @@
1
+ # Erubis For Rails2.3
2
+
3
+ A simple gem which can resolve some compatibility issues when using Erubis in Rails 2.3
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ gem 'erubis_for_rails23'
10
+
11
+ And then execute:
12
+
13
+ $ bundle
14
+
15
+ Or install it yourself as:
16
+
17
+ $ gem install erubis_for_rails23
18
+
19
+ ## Usage
20
+
21
+ Just install it and require it in your Rails 2.3 project
22
+
23
+ ## Contributing
24
+
25
+ 1. Fork it
26
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
27
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
28
+ 4. Push to the branch (`git push origin my-new-feature`)
29
+ 5. Create new Pull Request
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
@@ -0,0 +1,18 @@
1
+ Gem::Specification.new do |spec|
2
+ spec.name = 'erubis_for_rails23'
3
+ spec.version = '0.1'
4
+ spec.authors = ['Bachue Zhou']
5
+ spec.email = ['bachue.shu@gmail.com']
6
+ spec.description = %q{A simple gem which can resolve some compatibility issues when using Erubis in Rails 2.3}
7
+ spec.summary = %q{A simple gem which can resolve some compatibility issues when using Erubis in Rails 2.3}
8
+ spec.homepage = 'http://bachue.is-programmer.com'
9
+ spec.license = 'GPLv3'
10
+
11
+ spec.files = `git ls-files`.split($/)
12
+ spec.require_paths = ['lib']
13
+
14
+ spec.add_development_dependency 'bundler', '~> 1.3'
15
+ spec.add_development_dependency 'rake'
16
+
17
+ spec.add_dependency 'erubis'
18
+ end
@@ -0,0 +1,20 @@
1
+ require 'erubis'
2
+ require 'erb'
3
+
4
+ util = ERB::Util
5
+
6
+ Object.send :remove_const, :ERB
7
+ ERB = Erubis::Eruby
8
+ ERB::Util = util
9
+
10
+ class Erubis::Eruby # to be compatible with ERB constructor
11
+ def initialize(input = nil, *args)
12
+ if args.size.zero? || args.first.is_a?(Hash)
13
+ super
14
+ else
15
+ trim = args[1] == '-'
16
+ bufvar = args[2]
17
+ super input, :trim => trim, :bufvar => bufvar
18
+ end
19
+ end
20
+ end
metadata ADDED
@@ -0,0 +1,104 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: erubis_for_rails23
3
+ version: !ruby/object:Gem::Version
4
+ prerelease: false
5
+ segments:
6
+ - 0
7
+ - 1
8
+ version: "0.1"
9
+ platform: ruby
10
+ authors:
11
+ - Bachue Zhou
12
+ autorequire:
13
+ bindir: bin
14
+ cert_chain: []
15
+
16
+ date: 2013-10-10 00:00:00 +08:00
17
+ default_executable:
18
+ dependencies:
19
+ - !ruby/object:Gem::Dependency
20
+ version_requirements: &id001 !ruby/object:Gem::Requirement
21
+ requirements:
22
+ - - ~>
23
+ - !ruby/object:Gem::Version
24
+ segments:
25
+ - 1
26
+ - 3
27
+ version: "1.3"
28
+ requirement: *id001
29
+ prerelease: false
30
+ name: bundler
31
+ type: :development
32
+ - !ruby/object:Gem::Dependency
33
+ version_requirements: &id002 !ruby/object:Gem::Requirement
34
+ requirements:
35
+ - - ">="
36
+ - !ruby/object:Gem::Version
37
+ segments:
38
+ - 0
39
+ version: "0"
40
+ requirement: *id002
41
+ prerelease: false
42
+ name: rake
43
+ type: :development
44
+ - !ruby/object:Gem::Dependency
45
+ version_requirements: &id003 !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - ">="
48
+ - !ruby/object:Gem::Version
49
+ segments:
50
+ - 0
51
+ version: "0"
52
+ requirement: *id003
53
+ prerelease: false
54
+ name: erubis
55
+ type: :runtime
56
+ description: A simple gem which can resolve some compatibility issues when using Erubis in Rails 2.3
57
+ email:
58
+ - bachue.shu@gmail.com
59
+ executables: []
60
+
61
+ extensions: []
62
+
63
+ extra_rdoc_files: []
64
+
65
+ files:
66
+ - .gitignore
67
+ - Gemfile
68
+ - LICENSE.txt
69
+ - README.md
70
+ - Rakefile
71
+ - erubis_for_rails23.gemspec
72
+ - lib/erubis_for_rails23.rb
73
+ has_rdoc: true
74
+ homepage: http://bachue.is-programmer.com
75
+ licenses:
76
+ - GPLv3
77
+ post_install_message:
78
+ rdoc_options: []
79
+
80
+ require_paths:
81
+ - lib
82
+ required_ruby_version: !ruby/object:Gem::Requirement
83
+ requirements:
84
+ - - ">="
85
+ - !ruby/object:Gem::Version
86
+ segments:
87
+ - 0
88
+ version: "0"
89
+ required_rubygems_version: !ruby/object:Gem::Requirement
90
+ requirements:
91
+ - - ">="
92
+ - !ruby/object:Gem::Version
93
+ segments:
94
+ - 0
95
+ version: "0"
96
+ requirements: []
97
+
98
+ rubyforge_project:
99
+ rubygems_version: 1.3.6
100
+ signing_key:
101
+ specification_version: 3
102
+ summary: A simple gem which can resolve some compatibility issues when using Erubis in Rails 2.3
103
+ test_files: []
104
+