brighter_planet_layout-ruby19 0.2.37.1 → 0.2.40
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +16 -3
- data/VERSION +1 -1
- data/app/views/layouts/_elsewhere.html.erb +20 -1
- data/app/views/layouts/_footer.html.erb +2 -1
- data/app/views/layouts/_header.html.erb +1 -1
- data/brighter_planet_layout.gemspec +2 -6
- data/lib/brighter_planet_layout.rb +3 -11
- metadata +3 -6
- data/LICENSE +0 -20
data/README.rdoc
CHANGED
@@ -4,9 +4,22 @@
|
|
4
4
|
|
5
5
|
* You need to create <tt>app/views/layouts/_title.html.erb</tt> with something like:
|
6
6
|
|
7
|
-
<h1>
|
8
|
-
<h2>
|
7
|
+
<h1>Application Name</h1>
|
8
|
+
<h2>An exciting slogan</h2>
|
9
|
+
|
10
|
+
== Sites
|
11
|
+
|
12
|
+
+brighter_planet_layout+ is currently used by:
|
13
|
+
|
14
|
+
* {app1}[http://github.com/brighterplanet/app1]
|
15
|
+
* {cm1}[http://github.com/brighterplanet/cm1]
|
16
|
+
* {data1}[http://github.com/brighterplanet/data1]
|
17
|
+
* {keyring1}[http://github.com/brighterplanet/keyring1]
|
18
|
+
* {numbers}[http://github.com/brighterplanet.com/numbers] †
|
19
|
+
* {brighterplanet.github.com}[http://github.com/brighterplanet/brighterplanet.github.com] †
|
20
|
+
|
21
|
+
† <i>These sites do not use this gem directly. Run <tt>rake layout:build</tt> to update them to +brighter_planet_layout+ HEAD.</i>
|
9
22
|
|
10
23
|
== Copyright
|
11
24
|
|
12
|
-
Copyright (c) 2010 Andy Rossmeissl.
|
25
|
+
Copyright (c) 2010 Andy Rossmeissl.
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.40
|
@@ -1,5 +1,6 @@
|
|
1
1
|
<div id="elsewhere">
|
2
2
|
<% cache "#{__FILE__}/latest_tweet", :ttl => 3.minutes do %>
|
3
|
+
<!-- Cached at <%= Time.now %> -->
|
3
4
|
<% tweet = ::BrighterPlanetLayout.latest_tweet -%>
|
4
5
|
<% if tweet %>
|
5
6
|
<div id="twitter">
|
@@ -8,13 +9,31 @@
|
|
8
9
|
<span>via <%= link_to '@brighterplanet', 'http://twitter.com/brighterplanet' %></span>
|
9
10
|
</p>
|
10
11
|
</div>
|
12
|
+
<% else %>
|
13
|
+
<div id="twitter">
|
14
|
+
<p>
|
15
|
+
Check out our <a href="http://twitter.com/brighterplanet">Twitter feed</a>
|
16
|
+
<span>via <a href="http://twitter.com/brighterplanet">@brighterplanet</a></span>
|
17
|
+
</p>
|
18
|
+
</div>
|
11
19
|
<% end %>
|
12
20
|
<% end %>
|
13
21
|
<% cache "#{__FILE__}/latest_blog_post", :ttl => 3.minutes do %>
|
22
|
+
<!-- Cached at <%= Time.now %> -->
|
14
23
|
<% blog_post = ::BrighterPlanetLayout.latest_blog_post -%>
|
15
24
|
<% if blog_post %>
|
16
25
|
<div id="blog" class="<%= blog_post.author.downcase.dasherize %>">
|
17
|
-
<p
|
26
|
+
<p>
|
27
|
+
<%= link_to blog_post.title, blog_post.link %>
|
28
|
+
<span>by <%= blog_post.author %> <%= time_ago_in_words blog_post.updated %> ago on <%= link_to 'Safety in Numbers', 'http://numbers.brighterplanet.com' %>, our blog</span>
|
29
|
+
</p>
|
30
|
+
</div>
|
31
|
+
<% else %>
|
32
|
+
<div id="blog" class="andy">
|
33
|
+
<p>
|
34
|
+
See <a href="http://numbers.brighterplanet.com">the latest posts</a>
|
35
|
+
<span>by Andy on <a href="http://numbers.brighterplanet.com">Safety in Numbers</a>, our blog</span>
|
36
|
+
</p>
|
18
37
|
</div>
|
19
38
|
<% end %>
|
20
39
|
<% end %>
|
@@ -10,6 +10,7 @@
|
|
10
10
|
<li><%= link_to 'Data', 'http://data.brighterplanet.com' %></li>
|
11
11
|
<li><%= link_to_homesite 'Cards', 'cards' %></li>
|
12
12
|
<li><%= link_to_homesite 'Footprint', 'users/me/footprint' %></li>
|
13
|
+
<li><%= link_to 'Tests', 'http://tests.brighterplanet.com' %></li>
|
13
14
|
</ul>
|
14
15
|
</div>
|
15
16
|
<div id="map">
|
@@ -26,8 +27,8 @@
|
|
26
27
|
<p>Real-time, scalable web services to enhance your business applications. <%= link_to_homesite 'Learn more', 'middleware' %></p>
|
27
28
|
</div>
|
28
29
|
<ul class="links">
|
30
|
+
<li><%= link_to_homesite 'Information for executives', 'tour' %> Industry solutions and case studies</li>
|
29
31
|
<li><%= link_to 'Information for developers', 'http://brighterplanet.github.com' %> Documentation, code samples, and libraries</li>
|
30
|
-
<li><%= link_to_homesite 'Information for executives', 'products' %> Industry solutions and case studies</li>
|
31
32
|
</ul>
|
32
33
|
</div>
|
33
34
|
<div id="applications">
|
@@ -3,7 +3,7 @@
|
|
3
3
|
<ul>
|
4
4
|
<li><%= link_to_homesite 'Home' %></li>
|
5
5
|
<li><%= link_to_homesite 'About us', 'about' %></li>
|
6
|
-
<li><%= link_to_homesite '
|
6
|
+
<li><%= link_to_homesite 'Tour', 'tour' %></li>
|
7
7
|
<li><%= link_to 'Developers', 'http://brighterplanet.github.com' %></li>
|
8
8
|
<li><%= link_to 'Blog', 'http://numbers.brighterplanet.com/' %></li>
|
9
9
|
</ul>
|
@@ -1,8 +1,6 @@
|
|
1
|
-
# -*- encoding: utf-8 -*-
|
2
|
-
|
3
1
|
Gem::Specification.new do |s|
|
4
2
|
s.name = %q{brighter_planet_layout-ruby19}
|
5
|
-
s.version = "0.2.
|
3
|
+
s.version = "0.2.40"
|
6
4
|
|
7
5
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
8
6
|
s.authors = ["Andy Rossmeissl", "Seamus Abshere"]
|
@@ -10,14 +8,12 @@ Gem::Specification.new do |s|
|
|
10
8
|
s.description = %q{Layouts, partials, stylesheets, and images}
|
11
9
|
s.email = %q{andy@rossmeissl.net}
|
12
10
|
s.extra_rdoc_files = [
|
13
|
-
"
|
14
|
-
"README.rdoc"
|
11
|
+
"README.rdoc"
|
15
12
|
]
|
16
13
|
s.files = [
|
17
14
|
".document",
|
18
15
|
".gitattributes",
|
19
16
|
".gitignore",
|
20
|
-
"LICENSE",
|
21
17
|
"README.rdoc",
|
22
18
|
"Rakefile",
|
23
19
|
"VERSION",
|
@@ -2,15 +2,7 @@ require 'fileutils'
|
|
2
2
|
require 'yaml'
|
3
3
|
require 'simple-rss'
|
4
4
|
require 'open-uri'
|
5
|
-
|
6
|
-
# http://ph7spot.com/musings/system-timer
|
7
|
-
begin
|
8
|
-
require 'system_timer'
|
9
|
-
BrighterPlanetLayoutTimer = ::SystemTimer
|
10
|
-
rescue ::LoadError
|
11
|
-
require 'timeout'
|
12
|
-
BrighterPlanetLayoutTimer = ::Timeout
|
13
|
-
end
|
5
|
+
require 'timeout'
|
14
6
|
|
15
7
|
module BrighterPlanetLayout
|
16
8
|
GEM_ROOT = ::File.expand_path ::File.join(::File.dirname(__FILE__), '..')
|
@@ -80,7 +72,7 @@ module BrighterPlanetLayout
|
|
80
72
|
end
|
81
73
|
|
82
74
|
def self.latest_tweet
|
83
|
-
::
|
75
|
+
::Timeout.timeout(FEED_TIMEOUT) do
|
84
76
|
::SimpleRSS.parse(open(TWITTER_RSS)).entries.first
|
85
77
|
end
|
86
78
|
rescue ::OpenURI::HTTPError
|
@@ -92,7 +84,7 @@ module BrighterPlanetLayout
|
|
92
84
|
end
|
93
85
|
|
94
86
|
def self.latest_blog_post
|
95
|
-
::
|
87
|
+
::Timeout.timeout(FEED_TIMEOUT) do
|
96
88
|
::SimpleRSS.parse(open(BLOG_ATOM)).entries.first
|
97
89
|
end
|
98
90
|
rescue ::OpenURI::HTTPError
|
metadata
CHANGED
@@ -1,14 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: brighter_planet_layout-ruby19
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 71
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 2
|
9
|
-
-
|
10
|
-
|
11
|
-
version: 0.2.37.1
|
9
|
+
- 40
|
10
|
+
version: 0.2.40
|
12
11
|
platform: ruby
|
13
12
|
authors:
|
14
13
|
- Andy Rossmeissl
|
@@ -59,13 +58,11 @@ executables: []
|
|
59
58
|
extensions: []
|
60
59
|
|
61
60
|
extra_rdoc_files:
|
62
|
-
- LICENSE
|
63
61
|
- README.rdoc
|
64
62
|
files:
|
65
63
|
- .document
|
66
64
|
- .gitattributes
|
67
65
|
- .gitignore
|
68
|
-
- LICENSE
|
69
66
|
- README.rdoc
|
70
67
|
- Rakefile
|
71
68
|
- VERSION
|
data/LICENSE
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
Copyright (c) 2009 Andy Rossmeissl
|
2
|
-
|
3
|
-
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
-
a copy of this software and associated documentation files (the
|
5
|
-
"Software"), to deal in the Software without restriction, including
|
6
|
-
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
-
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
-
permit persons to whom the Software is furnished to do so, subject to
|
9
|
-
the following conditions:
|
10
|
-
|
11
|
-
The above copyright notice and this permission notice shall be
|
12
|
-
included in all copies or substantial portions of the Software.
|
13
|
-
|
14
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
-
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
-
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
-
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
-
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
-
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
-
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|