sinatra-seo 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/LICENSE ADDED
@@ -0,0 +1,19 @@
1
+ Copyright (c) 2010 Julio Javier Cicchelli
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy
4
+ of this software and associated documentation files (the "Software"), to deal
5
+ in the Software without restriction, including without limitation the rights
6
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
+ copies of the Software, and to permit persons to whom the Software is
8
+ furnished to do so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in
11
+ all copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
+ THE SOFTWARE.
data/README.markdown ADDED
@@ -0,0 +1,41 @@
1
+ # Sinatra SEO
2
+ This is a [Sinatra Extension][1] that renders for browser and AJAX calls any page or sub-pages located under the directory defined as *:views* and the layout file defined as *:layout* (if there is any) inside your [Sinatra][2] application.
3
+
4
+ ### Installation
5
+ In order to install this gem, you just need to install the gem from your command line like this:
6
+
7
+ $sudo gem install sinatra-seo
8
+
9
+ You should take into account that this library have the following dependencies:
10
+
11
+ * [sinatra][2]
12
+
13
+ ### Usage
14
+ ... description goes here...
15
+
16
+ ### Contributions
17
+ Everybody is welcome to contribute to this project by commenting the source code, suggesting modifications or new ideas, reporting bugs, writing some documentation and, of course, you're also welcome to contribute with patches as well!
18
+
19
+ In case you would like to contribute on this library, here's the list of extra dependencies you would need:
20
+
21
+ * [rspec][3]
22
+ * [rcov][4]
23
+ * [rack-test][5]
24
+
25
+ ### Contributors
26
+ * [Julio Javier Cicchelli][6]
27
+
28
+ ### Notes
29
+ This extension have been tested on the versions 1.8.6, 1.8.7 and 1.9.1 of the [Ruby interpreter][7].
30
+
31
+ ### License
32
+ This extension is licensed under the [MIT License][8].
33
+
34
+ [1]: http://www.sinatrarb.com/extensions.html
35
+ [2]: http://www.sinatrarb.com/
36
+ [3]: http://rspec.info/
37
+ [4]: http://eigenclass.org/hiki/rcov
38
+ [5]: http://gitrdoc.com/brynary/rack-test/tree/master
39
+ [6]: http://github.com/mr-rock
40
+ [7]: http://www.ruby-lang.org/en/
41
+ [8]: http://creativecommons.org/licenses/MIT/
data/Rakefile ADDED
@@ -0,0 +1,63 @@
1
+ require 'rubygems' if RUBY_VERSION.to_f < 1.9
2
+ require 'rake/clean'
3
+ require 'rake/gempackagetask'
4
+ require 'spec/rake/spectask'
5
+
6
+ GEM_COMMAND = RUBY_VERSION.to_f < 1.9 ? 'gem' : 'gem19'
7
+
8
+ CLEAN.include %w[cov/ pkg/]
9
+
10
+ desc 'Load the GemSpec definition file.'
11
+ load 'sinatra-seo.gemspec'
12
+
13
+ desc 'Package building.'
14
+ Rake::GemPackageTask.new GEM do |package|
15
+ package.gem_spec = GEM
16
+ package.need_tar = false
17
+ package.need_zip = false
18
+ end
19
+
20
+ desc "Install the generated Gem into your system."
21
+ task :install => [:clean, :package] do
22
+ sh "sudo #{GEM_COMMAND} install pkg/*.gem --no-ri --no-rdoc"
23
+ end
24
+
25
+ namespace :deployment do
26
+ desc "Deployment on both Github and my own Server repository."
27
+ task :repositories do
28
+ sh 'git checkout master'
29
+ sh 'git merge development'
30
+ sh 'git push github master --tags'
31
+ sh 'git push server master --tags'
32
+ sh 'git checkout development'
33
+ end
34
+
35
+ desc "Deployment on Gemcutter."
36
+ task :gemcutter => [:clean, :package] do
37
+ sh "#{GEM_COMMAND} push pkg/*.gem"
38
+ end
39
+ end
40
+
41
+ desc "Deployment on Github and Gemcutter."
42
+ task :deploy => ['deployment:repositories', 'deployment:gemcutter']
43
+
44
+ desc 'Functional testing with RSpec.'
45
+ Spec::Rake::SpecTask.new :spec do |task|
46
+ task.spec_opts = %w[--colour --format profile --loadby mtime --reverse --timeout 20 --diff]
47
+ task.libs = %w[lib spec]
48
+ task.spec_files = FileList['spec/**/*.rb']
49
+ task.rcov = false
50
+ end
51
+
52
+ desc 'Functional testing with RSpec and RCov.'
53
+ Spec::Rake::SpecTask.new :rcov do |task|
54
+ task.spec_opts = %w[--colour --format profile --loadby mtime --reverse --timeout 20 --diff]
55
+ task.libs = %w[lib spec]
56
+ task.spec_files = FileList['spec/*_spec.rb']
57
+ task.rcov = true
58
+ task.rcov_dir = 'cov'
59
+ task.rcov_opts = %w[--text-summary --exclude spec/]
60
+ end
61
+
62
+ desc "Default is Functional testing with RSpec."
63
+ task :default => [:spec]
@@ -0,0 +1,7 @@
1
+ require 'sinatra/base'
2
+
3
+ module Sinatra
4
+ module Seo
5
+ # ...
6
+ end
7
+ end
data/spec/seo_spec.rb ADDED
@@ -0,0 +1,9 @@
1
+ require 'spec_helper'
2
+
3
+ describe Sinatra::Seo do
4
+ include Rack::Test::Methods
5
+
6
+ def app
7
+ Sinatra::Application
8
+ end
9
+ end
@@ -0,0 +1,5 @@
1
+ require 'sinatra'
2
+ require 'rack/test'
3
+ require File.join(Dir.pwd, %w{lib sinatra seo})
4
+
5
+ set :environment, :test
metadata ADDED
@@ -0,0 +1,100 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: sinatra-seo
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Julio Javier Cicchelli
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+
12
+ date: 2010-03-10 00:00:00 +01:00
13
+ default_executable:
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: sinatra
17
+ type: :runtime
18
+ version_requirement:
19
+ version_requirements: !ruby/object:Gem::Requirement
20
+ requirements:
21
+ - - ">="
22
+ - !ruby/object:Gem::Version
23
+ version: 1.0a
24
+ version:
25
+ - !ruby/object:Gem::Dependency
26
+ name: rspec
27
+ type: :development
28
+ version_requirement:
29
+ version_requirements: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: 1.3.0
34
+ version:
35
+ - !ruby/object:Gem::Dependency
36
+ name: rcov
37
+ type: :development
38
+ version_requirement:
39
+ version_requirements: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - ">="
42
+ - !ruby/object:Gem::Version
43
+ version: 0.9.8
44
+ version:
45
+ - !ruby/object:Gem::Dependency
46
+ name: rack-test
47
+ type: :development
48
+ version_requirement:
49
+ version_requirements: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ version: 0.5.3
54
+ version:
55
+ description: " A Sinatra extension for integrating basic SEO into your Sinatra projects.\n"
56
+ email: javier@rock-n-code.com
57
+ executables: []
58
+
59
+ extensions: []
60
+
61
+ extra_rdoc_files: []
62
+
63
+ files:
64
+ - LICENSE
65
+ - README.markdown
66
+ - Rakefile
67
+ - lib/sinatra/seo.rb
68
+ - spec/seo_spec.rb
69
+ - spec/spec_helper.rb
70
+ has_rdoc: true
71
+ homepage: http://github.com/rock-n-code/sinatra-seo
72
+ licenses: []
73
+
74
+ post_install_message:
75
+ rdoc_options: []
76
+
77
+ require_paths:
78
+ - lib
79
+ required_ruby_version: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - ">="
82
+ - !ruby/object:Gem::Version
83
+ version: 1.8.6
84
+ version:
85
+ required_rubygems_version: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: 1.3.5
90
+ version:
91
+ requirements: []
92
+
93
+ rubyforge_project:
94
+ rubygems_version: 1.3.5
95
+ signing_key:
96
+ specification_version: 3
97
+ summary: A Sinatra extension for SEO integration.
98
+ test_files:
99
+ - spec/seo_spec.rb
100
+ - spec/spec_helper.rb