From 90d1bc26d896bb3208b7dd86521a5c3bd00c4dbc Mon Sep 17 00:00:00 2001 From: DBA Date: Tue, 24 Aug 2010 06:25:15 +0800 Subject: [PATCH] History - updated (2.2.0 & 2.2.1) Manifest - updated readme reference Readme - Converted to markdown - cleaned up Gemspec - updated to 2.2.1 --- History.txt | 9 +++++++++ Manifest.txt | 2 +- README.md | 42 ++++++++++++++++++++++++++++++++++++++++++ README.txt | 38 -------------------------------------- liquid.gemspec | 8 ++++---- 5 files changed, 56 insertions(+), 43 deletions(-) create mode 100644 README.md delete mode 100644 README.txt diff --git a/History.txt b/History.txt index 2f1c37f65..d140a206e 100644 --- a/History.txt +++ b/History.txt @@ -1,3 +1,12 @@ +2.2.1 / 2010-08-23 + +* Added support for literal tags + +2.2.0 / 2010-08-22 + +* Compatible with Ruby 1.8.7, 1.9.1 and 1.9.2-p0 +* Merged some changed made by the community + 1.9.0 / 2008-03-04 * Fixed gem install rake task diff --git a/Manifest.txt b/Manifest.txt index 593e0bfee..cbc3e8904 100644 --- a/Manifest.txt +++ b/Manifest.txt @@ -2,7 +2,7 @@ CHANGELOG History.txt MIT-LICENSE Manifest.txt -README.txt +README.md Rakefile init.rb lib/extras/liquid_view.rb diff --git a/README.md b/README.md new file mode 100644 index 000000000..b8f324d5d --- /dev/null +++ b/README.md @@ -0,0 +1,42 @@ +# Liquid template engine + +## Introduction + +Liquid is a template engine which I wrote for very specific requirements + +* It has to have beautiful and simple markup. Template engines which don't produce good looking markup are no fun to use. +* It needs to be non evaling and secure. Liquid templates are made so that users can edit them. You don't want to run code on your server which your users wrote. +* It has to be stateless. Compile and render steps have to be seperate so that the expensive parsing and compiling can be done once and later on you can just render it passing in a hash with local variables and objects. + +## Why should I use Liquid + +* You want to allow your users to edit the appearance of your application but don't want them to run **insecure code on your server**. +* You want to render templates directly from the database +* You like smarty (PHP) style template engines +* You need a template engine which does HTML just as well as emails +* You don't like the markup of your current templating engine + +## What does it look like? + +
+
+
+ +## Howto use Liquid + +Liquid supports a very simple API based around the Liquid::Template class. +For standard use you can just pass it the content of a file and call render with a parameters hash. + +
+@template = Liquid::Template.parse("hi {{name}}") # Parses and compiles the template
+@template.render( 'name' => 'tobi' )              # => "hi tobi"
+
\ No newline at end of file diff --git a/README.txt b/README.txt deleted file mode 100644 index 1d019af6f..000000000 --- a/README.txt +++ /dev/null @@ -1,38 +0,0 @@ -= Liquid template engine - -Liquid is a template engine which I wrote for very specific requirements - -* It has to have beautiful and simple markup. - Template engines which don't produce good looking markup are no fun to use. -* It needs to be non evaling and secure. Liquid templates are made so that users can edit them. You don't want to run code on your server which your users wrote. -* It has to be stateless. Compile and render steps have to be seperate so that the expensive parsing and compiling can be done once and later on you can - just render it passing in a hash with local variables and objects. - -== Why should i use Liquid - -* You want to allow your users to edit the appearance of your application but don't want them to run insecure code on your server. -* You want to render templates directly from the database -* You like smarty style template engines -* You need a template engine which does HTML just as well as Emails -* You don't like the markup of your current one - -== What does it look like? - - - -== Howto use Liquid - -Liquid supports a very simple API based around the Liquid::Template class. -For standard use you can just pass it the content of a file and call render with a parameters hash. - - @template = Liquid::Template.parse("hi {{name}}") # Parses and compiles the template - @template.render( 'name' => 'tobi' ) # => "hi tobi" \ No newline at end of file diff --git a/liquid.gemspec b/liquid.gemspec index a2b5966ab..ed7891714 100644 --- a/liquid.gemspec +++ b/liquid.gemspec @@ -1,16 +1,16 @@ Gem::Specification.new do |s| s.name = %q{liquid} - s.version = "2.1.3" + s.version = "2.2.1" s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version= s.authors = ["Tobias Luetke"] s.description = %q{A secure, non-evaling end user template engine with aesthetic markup.} s.email = %q{tobi@leetsoft.com} - s.extra_rdoc_files = ["History.txt", "Manifest.txt", "README.txt"] - s.files = ["CHANGELOG", "History.txt", "MIT-LICENSE", "Manifest.txt", "README.txt", "Rakefile", "lib/extras/liquid_view.rb", "lib/liquid.rb", "lib/liquid/block.rb", "lib/liquid/condition.rb", "lib/liquid/context.rb", "lib/liquid/document.rb", "lib/liquid/drop.rb", "lib/liquid/errors.rb", "lib/liquid/extensions.rb", "lib/liquid/file_system.rb", "lib/liquid/htmltags.rb", "lib/liquid/module_ex.rb", "lib/liquid/standardfilters.rb", "lib/liquid/strainer.rb", "lib/liquid/tag.rb", "lib/liquid/tags/assign.rb", "lib/liquid/tags/capture.rb", "lib/liquid/tags/case.rb", "lib/liquid/tags/comment.rb", "lib/liquid/tags/cycle.rb", "lib/liquid/tags/for.rb", "lib/liquid/tags/if.rb", "lib/liquid/tags/ifchanged.rb", "lib/liquid/tags/include.rb", "lib/liquid/tags/unless.rb", "lib/liquid/template.rb", "lib/liquid/variable.rb"] + s.extra_rdoc_files = ["History.txt", "Manifest.txt", "README.md"] + s.files = ["CHANGELOG", "History.txt", "MIT-LICENSE", "Manifest.txt", "README.md", "Rakefile", "lib/extras/liquid_view.rb", "lib/liquid.rb", "lib/liquid/block.rb", "lib/liquid/condition.rb", "lib/liquid/context.rb", "lib/liquid/document.rb", "lib/liquid/drop.rb", "lib/liquid/errors.rb", "lib/liquid/extensions.rb", "lib/liquid/file_system.rb", "lib/liquid/htmltags.rb", "lib/liquid/module_ex.rb", "lib/liquid/standardfilters.rb", "lib/liquid/strainer.rb", "lib/liquid/tag.rb", "lib/liquid/tags/assign.rb", "lib/liquid/tags/capture.rb", "lib/liquid/tags/case.rb", "lib/liquid/tags/comment.rb", "lib/liquid/tags/cycle.rb", "lib/liquid/tags/for.rb", "lib/liquid/tags/if.rb", "lib/liquid/tags/ifchanged.rb", "lib/liquid/tags/include.rb", "lib/liquid/tags/unless.rb", "lib/liquid/template.rb", "lib/liquid/variable.rb"] s.has_rdoc = true s.homepage = %q{http://www.liquidmarkup.org} - s.rdoc_options = ["--main", "README.txt"] + s.rdoc_options = ["--main", "README.md"] s.require_paths = ["lib"] s.rubyforge_project = %q{liquid} s.rubygems_version = %q{1.3.1}