Permalink
Browse files

tweaking app

  • Loading branch information...
1 parent f6dcce0 commit e2d11a0fe5cec84fd85edbfa595500e8eba844f4 @wbzyl committed May 22, 2009
Showing with 27 additions and 34 deletions.
  1. +5 −2 .gitignore
  2. +1 −1 LICENSE
  3. +12 −14 README.markdown
  4. +5 −13 Rakefile
  5. +4 −4 sinatra-rdiscount.gemspec
View
@@ -1,2 +1,5 @@
-pkg/*
-*.gem
+pkg
+*~
+\#*
+.\#*
+
View
@@ -1,6 +1,6 @@
(The MIT License)
-Copyright (c) 2008 Wlodek Bzyl
+Copyright (c) 2009 Wlodek Bzyl
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
View
@@ -1,39 +1,37 @@
-# Extension providing RDiscount templates for Sinatra apps
+# Sinatra RDiscount Extension
-The *sinatra-rdiscount* gem is an extension for Sinatra
-implemented as a gem.
-It provides a request-helper method named `rdiscount`
+The *sinatra-rdiscount* extension provides `rdiscount` helper method
for rendering RDiscount templates.
-To use this extension, first install *sinatra-rdiscount* gem:
+To install it, run:
sudo gem install wbzyl-sinatra-rdiscount -s http://gems.github.com
-Then create a simple Sinatra application *app.rb*:
+To test it, create a simple Sinatra application:
+ # app.rb
require 'rubygems'
require 'sinatra'
- gem 'wbzyl-sinatra-rdiscount', '>=0.1.2'
+ gem 'wbzyl-sinatra-rdiscount', '>=0.1.4'
require 'sinatra/rdiscount'
get "/" do
- rdiscount "# Hello Rdiscount"
+ rdiscount "# Hello RDiscount"
end
-and run the above code:
+and run it with:
ruby app.rb
-The result could be seen here: *http://localhost:4567*.
+The result could be seen at *http://localhost:4567*.
-Another example could be find in the *examples* directory.
-Run it with:
+Another example could be find in the *examples* directory. Run it with:
rackup -p 4567 config.ru
-Now, visit the following url *http://localhost:4567/hello2*
-and contemplate the sheer beauty of the rendered code.
+and visit *http://localhost:4567/hello2* to contemplate the sheer
+beauty of the rendered "Hello RDiscount".
## Template Languages (*update to The Sinatra Book*)
View
@@ -1,5 +1,3 @@
-# -*- coding: utf-8 -*-
-
require 'rake'
require 'rake/testtask'
require "rake/clean"
@@ -8,11 +6,11 @@ begin
require 'jeweler'
Jeweler::Tasks.new do |gem|
gem.name = "sinatra-rdiscount"
- gem.summary = "An extension providing RDiscount templates for Sinatra applicationgem."
+ gem.summary = "Sinatra extension providing RDiscount templates for Sinatra application."
gem.email = "matwb@univ.gda.pl"
gem.homepage = "http://github.com/wbzyl/sinatra-rdiscount"
- gem.description = "An extension providing RDiscount templates for Sinatra applicationgem."
- gem.authors = ["Włodek Bzyl"]
+ gem.description = gem.summary
+ gem.authors = ["Wlodek Bzyl"]
gem.add_runtime_dependency 'sinatra', '>= 0.9.2'
gem.add_runtime_dependency 'erubis', '>=2.6.4'
@@ -21,8 +19,8 @@ begin
gem.add_development_dependency 'rack', '>=1.0.0'
gem.add_development_dependency 'rack-test', '>=0.3.0'
- # gem is a Gem::Specification...
- # see http://www.rubygems.org/read/chapter/20 for additional settings
+ # gem is a Gem::Specification
+ # refer to http://www.rubygems.org/read/chapter/20 for additional settings
end
rescue LoadError
puts "Jeweler not available."
@@ -35,9 +33,3 @@ Rake::TestTask.new(:test) do |t|
t.pattern = 'test/**/*_test.rb'
t.verbose = false
end
-
-desc 'Install the package as a gem.'
-task :install => [:clean, :build] do
- gem = Dir['pkg/*.gem'].last
- sh "sudo gem install --no-rdoc --no-ri --local #{gem}"
-end
@@ -2,12 +2,12 @@
Gem::Specification.new do |s|
s.name = %q{sinatra-rdiscount}
- s.version = "0.1.2"
+ s.version = "0.1.4"
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
- s.authors = ["W\305\202odek Bzyl"]
+ s.authors = ["Wlodek Bzyl"]
s.date = %q{2009-05-22}
- s.description = %q{An extension providing RDiscount templates for Sinatra applicationgem.}
+ s.description = %q{Sinatra extension providing RDiscount templates for Sinatra application.}
s.email = %q{matwb@univ.gda.pl}
s.extra_rdoc_files = [
"LICENSE",
@@ -37,7 +37,7 @@ Gem::Specification.new do |s|
s.rdoc_options = ["--charset=UTF-8"]
s.require_paths = ["lib"]
s.rubygems_version = %q{1.3.3}
- s.summary = %q{An extension providing RDiscount templates for Sinatra applicationgem.}
+ s.summary = %q{Sinatra extension providing RDiscount templates for Sinatra application.}
s.test_files = [
"test/test_helper.rb",
"test/sinatra_rdiscount_test.rb",

0 comments on commit e2d11a0

Please sign in to comment.