| ... | ... |
@@ -156,6 +156,15 @@ module Helpers |
| 156 | 156 |
|
| 157 | 157 |
# My added helpers |
| 158 | 158 |
|
| 159 |
+ def show_part (file) |
|
| 160 |
+ data = '' |
|
| 161 |
+ f = File.open(Dir.pwd+"/source/"+file) |
|
| 162 |
+ f.each_line do |line| |
|
| 163 |
+ data += line |
|
| 164 |
+ end |
|
| 165 |
+ data |
|
| 166 |
+ end |
|
| 167 |
+ |
|
| 159 | 168 |
def shorten_words (string, word_limit = 25) |
| 160 | 169 |
words = string.split(/\s/) |
| 161 | 170 |
if words.size >= word_limit |
| ... | ... |
@@ -6,6 +6,7 @@ tweet_count: 3 |
| 6 | 6 |
show_replies: false |
| 7 | 7 |
|
| 8 | 8 |
delicious_user: imathis |
| 9 |
+delicious_count: 3 |
|
| 9 | 10 |
|
| 10 | 11 |
full_url: |
| 11 | 12 |
disqus_short_name: |
| ... | ... |
@@ -82,13 +83,13 @@ google_analytics: true |
| 82 | 82 |
- if page.respond_to? :delicious_user |
| 83 | 83 |
%h4 My Delicious <a class="small" href="http://delicious.com/#{page.delicious_user}">more →</a>
|
| 84 | 84 |
#delicious |
| 85 |
- %script(type="text/javascript" src="http://feeds.delicious.com/v2/js/#{page.delicious_user}?title=&count=5&sort=date&extended")
|
|
| 85 |
+ %script(type="text/javascript" src="http://feeds.delicious.com/v2/js/#{page.delicious_user}?title=&count=#{page.delicious_count}&sort=date&extended")
|
|
| 86 | 86 |
#footer |
| 87 | 87 |
.page_width |
| 88 | 88 |
Copyright © #{Time.now.strftime('%Y')} - #{page.blog_title} -
|
| 89 | 89 |
%span.credit Powered by <a href="http://github.com/imathis/octopress/">Octopress</a> |
| 90 | 90 |
- if page.respond_to? :disqus_short_name |
| 91 |
- //Disqus Commens code |
|
| 91 |
+ //Disqus Comments code |
|
| 92 | 92 |
:javascript |
| 93 | 93 |
(function() {
|
| 94 | 94 |
var links = document.getElementsByTagName('a');
|
| ... | ... |
@@ -140,7 +140,7 @@ var TwitterGitter = new Class({
|
| 140 | 140 |
//format |
| 141 | 141 |
linkify: function(text) {
|
| 142 | 142 |
//courtesy of Jeremy Parrish (rrish.org) |
| 143 |
- return text.replace(/(https?:\/\/\S+)/gi,'<a href="$1">$1</a>').replace(/(^|\s)@(\w+)/g,'$1<a href="http://twitter.com/$2">@$2</a>').replace(/(^|\s)#(\w+)/g,'$1<a href="http://search.twitter.com/search?q=%23$2">#$2</a>'); |
|
| 143 |
+ return text.replace(/(https?:\/\/[\w\-:;?&=+.%#\/]+)/gi,'<a href="$1">$1</a>').replace(/(^|\s)@(\w+)/g,'$1<a class="user" href="http://twitter.com/$2">@$2</a>').replace(/(^|\s)#(\w+)/g,'$1<a class="topic" href="http://search.twitter.com/search?q=%23$2">#$2</a>'); |
|
| 144 | 144 |
} |
| 145 | 145 |
}); |
| 146 | 146 |
//Compact Jsonp from http://clientcide.com/js |
| ... | ... |
@@ -42,9 +42,4 @@ |
| 42 | 42 |
!textinput_border_right = #c3c3c3 |
| 43 | 43 |
!textinput_border_focus = #989898 |
| 44 | 44 |
|
| 45 |
-!cancel_link = #555 |
|
| 46 |
- |
|
| 47 |
-// Button Colors |
|
| 48 |
-!default_button_text_color = #fff |
|
| 49 |
-!default_button_bg = yellow |
|
| 50 |
-!blue_btn = desaturate(adjust_hue(!default_button_bg, -16), 25) |
|
| 51 | 45 |
\ No newline at end of file |
| 46 |
+!twitter_topic = #888 |
|
| 52 | 47 |
\ No newline at end of file |
| ... | ... |
@@ -9,13 +9,29 @@ |
| 9 | 9 |
margin-top: 10px |
| 10 | 10 |
.small |
| 11 | 11 |
+sans-font |
| 12 |
- font-size: 50% |
|
| 12 |
+ font-size: 50% |
|
| 13 |
+ font-size: 80% |
|
| 14 |
+ line-height: 1.625em |
|
| 15 |
+ |
|
| 16 |
+#twitter, #delicious |
|
| 17 |
+ +border-radius |
|
| 18 |
+ background: #f8f8f8 |
|
| 19 |
+ border: 1px solid #eee |
|
| 20 |
+ padding: 5px 0 |
|
| 21 |
+ ul |
|
| 22 |
+ list-style-type: none |
|
| 23 |
+ margin: 0 |
|
| 24 |
+ li |
|
| 25 |
+ margin: 0 15px |
|
| 26 |
+ padding: 10px 0 0 |
|
| 27 |
+ border-bottom: #ddd 1px dashed |
|
| 28 |
+ &:last-child |
|
| 29 |
+ border-bottom: 0 |
|
| 13 | 30 |
|
| 14 | 31 |
#delicious |
| 15 | 32 |
p |
| 16 | 33 |
font-style: italic |
| 17 | 34 |
li |
| 18 |
- font-size: 90% |
|
| 19 | 35 |
color: #666 |
| 20 | 36 |
font-style: normal |
| 21 | 37 |
padding-bottom: 8px |
| 22 | 38 |
\ No newline at end of file |
| ... | ... |
@@ -1,28 +1,15 @@ |
| 1 | 1 |
|
| 2 |
- font-size: 80% |
|
| 3 |
- +border-radius |
|
| 4 |
- background: #f8f8f8 |
|
| 5 |
- border: 1px solid #eee |
|
| 6 |
- padding: 5px 0 |
|
| 7 |
- ul |
|
| 8 |
- list-style-type: none |
|
| 9 |
- margin: 0 |
|
| 10 |
- li |
|
| 11 |
- margin: 0 15px |
|
| 12 |
- padding: 10px 0 0 |
|
| 13 |
- border-bottom: #ddd 1px dashed |
|
| 14 |
- line-height: 1.625em |
|
| 15 |
- &:last-child |
|
| 16 |
- border-bottom: 0 |
|
| 17 |
- p |
|
| 18 |
- padding-bottom: 10px |
|
| 19 |
- .meta |
|
| 20 |
- color= !light_text |
|
| 21 |
- font-size: 80% |
|
| 22 |
- display: block |
|
| 23 |
- padding: 8px 0 0 |
|
| 24 |
- a |
|
| 25 |
- color: inherit |
|
| 26 |
- text-decoration: none |
|
| 27 |
- &:hover |
|
| 28 |
- text-decoration: underline |
|
| 29 | 2 |
\ No newline at end of file |
| 3 |
+ p |
|
| 4 |
+ padding-bottom: 10px |
|
| 5 |
+ a.topic |
|
| 6 |
+ color= !twitter_topic |
|
| 7 |
+ .meta |
|
| 8 |
+ color= !light_text |
|
| 9 |
+ font-size: 80% |
|
| 10 |
+ display: block |
|
| 11 |
+ padding: 8px 0 0 |
|
| 12 |
+ a |
|
| 13 |
+ color: inherit |
|
| 14 |
+ text-decoration: none |
|
| 15 |
+ &:hover |
|
| 16 |
+ text-decoration: underline |
|
| 30 | 17 |
\ No newline at end of file |