happy-titles 0.9.1 → 1.0.0

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.
data/README.markdown CHANGED
@@ -1,12 +1,26 @@
1
1
  # Happy Titles!
2
2
 
3
- A simple Rails plugin which adds an easy (and cheerful) way to handle page titles in your layouts.
3
+ A simple (and cheerful) way to handle page titles in your layouts.
4
4
 
5
5
  ## Getting Started
6
6
 
7
- ### Install the Plugin
7
+ ### Install the Gem
8
8
 
9
- script/plugin install git://github.com/andypearson/happy-titles.git
9
+ #### In Rails 3
10
+
11
+ Add the following to your Gemfile
12
+
13
+ gem 'happy-titles'
14
+
15
+ #### In Rails 2
16
+
17
+ Run the following:
18
+
19
+ sudo gem install happy-titles
20
+
21
+ And add it to your environment.rb configuration as a gem dependency:
22
+
23
+ config.gem "happy-titles", :lib => 'happy_titles'
10
24
 
11
25
  ### Set the Defaults
12
26
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.9.1
1
+ 1.0.0
data/happy-titles.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{happy-titles}
8
- s.version = "0.9.1"
8
+ s.version = "1.0.0"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Andy Pearson"]
12
- s.date = %q{2010-06-01}
12
+ s.date = %q{2010-09-14}
13
13
  s.email = %q{andy@andy-pearson.com}
14
14
  s.extra_rdoc_files = [
15
15
  "README.markdown"
@@ -22,7 +22,9 @@ Gem::Specification.new do |s|
22
22
  "Rakefile",
23
23
  "VERSION",
24
24
  "happy-titles.gemspec",
25
- "lib/happy_titles.rb",
25
+ "init.rb",
26
+ "lib/happy-titles.rb",
27
+ "lib/happy-titles/railtie.rb",
26
28
  "rails/init.rb",
27
29
  "spec/happy_titles_spec.rb",
28
30
  "spec/spec_helper.rb"
data/init.rb ADDED
@@ -0,0 +1,2 @@
1
+ require 'happy-titles'
2
+ ActionView::Base.send :include, HappyTitles
@@ -0,0 +1,10 @@
1
+ require 'happy-titles'
2
+ require 'rails'
3
+
4
+ module HappyTitles
5
+ class Railtie < Rails::Railtie
6
+ initializer 'happy-titles.initialize', :after => :after_initialize do
7
+ ActionView::Base.send :include, HappyTitles
8
+ end
9
+ end
10
+ end
@@ -1,3 +1,5 @@
1
+ require File.join(File.dirname(__FILE__), *%w[happy-titles railtie]) if defined?(::Rails::Railtie)
2
+
1
3
  module HappyTitles
2
4
 
3
5
  attr_accessor :page_title
data/rails/init.rb CHANGED
@@ -1,2 +1,2 @@
1
- require File.join(File.dirname(__FILE__), *%w[.. lib happy_titles])
2
- ActionView::Base.send(:include, HappyTitles)
1
+ # coding: utf-8
2
+ require File.expand_path(File.join(File.dirname(__FILE__), "..", "init"))
data/spec/spec_helper.rb CHANGED
@@ -14,7 +14,7 @@ gem 'hpricot', '>= 0.6.1'
14
14
  gem 'rspec_tag_matchers', '>= 1.0.0'
15
15
  require 'rspec_tag_matchers'
16
16
 
17
- require File.join(File.dirname(__FILE__), "../lib/happy_titles")
17
+ require File.join(File.dirname(__FILE__), "../lib/happy-titles")
18
18
 
19
19
  Spec::Runner.configure do |config|
20
20
  config.include(RspecTagMatchers)
metadata CHANGED
@@ -3,10 +3,10 @@ name: happy-titles
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease: false
5
5
  segments:
6
- - 0
7
- - 9
8
6
  - 1
9
- version: 0.9.1
7
+ - 0
8
+ - 0
9
+ version: 1.0.0
10
10
  platform: ruby
11
11
  authors:
12
12
  - Andy Pearson
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-06-01 00:00:00 +01:00
17
+ date: 2010-09-14 00:00:00 +01:00
18
18
  default_executable:
19
19
  dependencies: []
20
20
 
@@ -34,7 +34,9 @@ files:
34
34
  - Rakefile
35
35
  - VERSION
36
36
  - happy-titles.gemspec
37
- - lib/happy_titles.rb
37
+ - init.rb
38
+ - lib/happy-titles.rb
39
+ - lib/happy-titles/railtie.rb
38
40
  - rails/init.rb
39
41
  - spec/happy_titles_spec.rb
40
42
  - spec/spec_helper.rb