ruhoh 1.1 → 2.1
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/Gemfile +3 -3
- data/README.md +3 -2
- data/Rakefile +1 -22
- data/bin/ruhoh +1 -5
- data/history.json +16 -0
- data/lib/ruhoh.rb +229 -84
- data/lib/ruhoh/base/collection.rb +280 -0
- data/lib/ruhoh/base/compiler.rb +55 -0
- data/lib/ruhoh/base/model.rb +220 -0
- data/lib/ruhoh/base/model_view.rb +152 -0
- data/lib/ruhoh/base/watcher.rb +25 -0
- data/lib/ruhoh/cache.rb +46 -0
- data/lib/ruhoh/client.rb +162 -0
- data/lib/ruhoh/collections.rb +172 -0
- data/lib/ruhoh/console_methods.rb +21 -0
- data/lib/ruhoh/{converters/converter.rb → converter.rb} +4 -1
- data/lib/ruhoh/programs/compile.rb +22 -0
- data/lib/ruhoh/programs/preview.rb +63 -0
- data/lib/ruhoh/programs/watch.rb +45 -0
- data/lib/ruhoh/resources/dash/collection.rb +10 -0
- data/lib/ruhoh/resources/dash/model.rb +5 -0
- data/lib/ruhoh/resources/dash/model_view.rb +5 -0
- data/lib/ruhoh/resources/dash/previewer.rb +13 -0
- data/lib/ruhoh/resources/data/collection.rb +9 -0
- data/lib/ruhoh/resources/data/collection_view.rb +23 -0
- data/lib/ruhoh/resources/javascripts/collection.rb +9 -0
- data/lib/ruhoh/resources/javascripts/collection_view.rb +46 -0
- data/lib/ruhoh/resources/javascripts/compiler.rb +5 -0
- data/lib/ruhoh/resources/layouts/client.rb +45 -0
- data/lib/ruhoh/resources/layouts/model.rb +16 -0
- data/lib/ruhoh/resources/media/collection.rb +9 -0
- data/lib/ruhoh/resources/media/compiler.rb +27 -0
- data/lib/ruhoh/resources/pages/client.rb +124 -0
- data/lib/ruhoh/resources/pages/collection.rb +86 -0
- data/lib/ruhoh/resources/pages/collection_view.rb +73 -0
- data/lib/ruhoh/resources/pages/compiler.rb +101 -0
- data/lib/ruhoh/resources/pages/model.rb +5 -0
- data/lib/ruhoh/resources/pages/model_view.rb +5 -0
- data/lib/ruhoh/resources/pages/previewer.rb +72 -0
- data/lib/ruhoh/resources/partials/model.rb +11 -0
- data/lib/ruhoh/resources/stylesheets/collection.rb +9 -0
- data/lib/ruhoh/resources/stylesheets/collection_view.rb +45 -0
- data/lib/ruhoh/resources/stylesheets/compiler.rb +5 -0
- data/lib/ruhoh/resources/theme/collection.rb +14 -0
- data/lib/ruhoh/resources/theme/compiler.rb +54 -0
- data/lib/ruhoh/resources/widgets/collection.rb +26 -0
- data/lib/ruhoh/resources/widgets/collection_view.rb +34 -0
- data/lib/ruhoh/resources/widgets/compiler.rb +27 -0
- data/lib/ruhoh/resources/widgets/model.rb +16 -0
- data/lib/ruhoh/routes.rb +29 -0
- data/lib/ruhoh/utils.rb +32 -49
- data/lib/ruhoh/version.rb +2 -2
- data/lib/ruhoh/views/helpers/categories.rb +38 -0
- data/lib/ruhoh/views/helpers/paginator.rb +39 -0
- data/lib/ruhoh/views/helpers/tags.rb +37 -0
- data/lib/ruhoh/views/master_view.rb +183 -0
- data/lib/ruhoh/views/rmustache.rb +24 -0
- data/ruhoh.gemspec +6 -82
- data/spec/spec_helper.rb +1 -1
- data/spec/support/shared_contexts.rb +6 -5
- data/system/{scaffolds/post.html → _scaffold.html} +1 -1
- data/system/{dash.html → dash/index.html} +37 -51
- data/system/{scaffolds/layout.html → layouts/_scaffold.html} +0 -0
- data/system/layouts/paginator.html +28 -0
- data/system/plugins/sprockets/javascripts/compiler.rb +25 -0
- data/system/plugins/sprockets/javascripts/previewer.rb +17 -0
- data/system/plugins/sprockets/stylesheets/compiler.rb +26 -0
- data/system/plugins/sprockets/stylesheets/previewer.rb +17 -0
- data/system/widgets/analytics/{layouts/getclicky.html → getclicky.html} +6 -2
- data/system/widgets/analytics/{layouts/google.html → google.html} +5 -1
- data/system/widgets/comments/{layouts/disqus.html → disqus.html} +6 -2
- data/system/widgets/comments/{layouts/facebook.html → facebook.html} +9 -2
- data/system/widgets/comments/{layouts/intensedebate.html → intensedebate.html} +5 -1
- data/system/widgets/comments/{layouts/livefyre.html → livefyre.html} +5 -1
- data/system/widgets/google_prettify/{layouts/google_prettify.html → default.html} +6 -2
- metadata +69 -66
- data/lib/ruhoh/client/client.rb +0 -306
- data/lib/ruhoh/client/console_methods.rb +0 -9
- data/lib/ruhoh/client/help.yml +0 -56
- data/lib/ruhoh/compiler.rb +0 -72
- data/lib/ruhoh/compilers/rss.rb +0 -39
- data/lib/ruhoh/compilers/theme.rb +0 -46
- data/lib/ruhoh/config.rb +0 -62
- data/lib/ruhoh/db.rb +0 -50
- data/lib/ruhoh/deployers/s3.rb +0 -71
- data/lib/ruhoh/page.rb +0 -106
- data/lib/ruhoh/parsers/javascripts.rb +0 -55
- data/lib/ruhoh/parsers/layouts.rb +0 -32
- data/lib/ruhoh/parsers/pages.rb +0 -79
- data/lib/ruhoh/parsers/partials.rb +0 -42
- data/lib/ruhoh/parsers/payload.rb +0 -49
- data/lib/ruhoh/parsers/posts.rb +0 -259
- data/lib/ruhoh/parsers/routes.rb +0 -20
- data/lib/ruhoh/parsers/scaffolds.rb +0 -35
- data/lib/ruhoh/parsers/site.rb +0 -19
- data/lib/ruhoh/parsers/stylesheets.rb +0 -63
- data/lib/ruhoh/parsers/theme_config.rb +0 -30
- data/lib/ruhoh/parsers/widgets.rb +0 -104
- data/lib/ruhoh/paths.rb +0 -83
- data/lib/ruhoh/previewer.rb +0 -48
- data/lib/ruhoh/program.rb +0 -68
- data/lib/ruhoh/templaters/asset_helpers.rb +0 -66
- data/lib/ruhoh/templaters/base_helpers.rb +0 -147
- data/lib/ruhoh/templaters/helpers.rb +0 -8
- data/lib/ruhoh/templaters/rmustache.rb +0 -70
- data/lib/ruhoh/urls.rb +0 -50
- data/lib/ruhoh/watch.rb +0 -78
- data/spec/config_spec.rb +0 -50
- data/spec/db_spec.rb +0 -91
- data/spec/page_spec.rb +0 -164
- data/spec/parsers/layouts_spec.rb +0 -41
- data/spec/parsers/pages_spec.rb +0 -120
- data/spec/parsers/posts_spec.rb +0 -309
- data/spec/parsers/routes_spec.rb +0 -39
- data/spec/parsers/site_spec.rb +0 -28
- data/spec/setup_spec.rb +0 -12
- data/system/scaffolds/draft.html +0 -9
- data/system/scaffolds/page.html +0 -4
- data/system/widgets/analytics/config.yml +0 -5
- data/system/widgets/comments/config.yml +0 -13
- data/system/widgets/google_prettify/config.yml +0 -1
@@ -0,0 +1,24 @@
|
|
1
|
+
module Ruhoh::Views
|
2
|
+
class RMustache < Mustache
|
3
|
+
class RContext < Context
|
4
|
+
|
5
|
+
# Overload find method to catch helper expressions
|
6
|
+
def find(obj, key, default = nil)
|
7
|
+
return super unless key.to_s.index('?')
|
8
|
+
keys = key.to_s.split('?')
|
9
|
+
context = keys[0]
|
10
|
+
helpers = keys[1..-1]
|
11
|
+
context = context.empty? ? obj : super(obj, context)
|
12
|
+
|
13
|
+
helpers.each do |helper|
|
14
|
+
context = self.mustache_in_stack.__send__ helper, context
|
15
|
+
end
|
16
|
+
context
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
def context
|
21
|
+
@context ||= RContext.new(self)
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
data/ruhoh.gemspec
CHANGED
@@ -16,88 +16,12 @@ Gem::Specification.new do |s|
|
|
16
16
|
# dependencies defined in Gemfile
|
17
17
|
s.add_dependency 'rack', "~> 1.4"
|
18
18
|
s.add_dependency 'mustache', "~> 0.99"
|
19
|
-
s.add_dependency 'directory_watcher', "~> 1.4"
|
19
|
+
s.add_dependency 'directory_watcher', "~> 1.4.0"
|
20
20
|
s.add_dependency 'redcarpet', "~> 2.1"
|
21
21
|
s.add_dependency 'nokogiri', "~> 1.5"
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
Rakefile
|
28
|
-
bin/ruhoh
|
29
|
-
history.json
|
30
|
-
lib/ruhoh.rb
|
31
|
-
lib/ruhoh/client/client.rb
|
32
|
-
lib/ruhoh/client/console_methods.rb
|
33
|
-
lib/ruhoh/client/help.yml
|
34
|
-
lib/ruhoh/compiler.rb
|
35
|
-
lib/ruhoh/compilers/rss.rb
|
36
|
-
lib/ruhoh/compilers/theme.rb
|
37
|
-
lib/ruhoh/config.rb
|
38
|
-
lib/ruhoh/converters/converter.rb
|
39
|
-
lib/ruhoh/converters/markdown.rb
|
40
|
-
lib/ruhoh/db.rb
|
41
|
-
lib/ruhoh/deployers/s3.rb
|
42
|
-
lib/ruhoh/friend.rb
|
43
|
-
lib/ruhoh/logger.rb
|
44
|
-
lib/ruhoh/page.rb
|
45
|
-
lib/ruhoh/parsers/javascripts.rb
|
46
|
-
lib/ruhoh/parsers/layouts.rb
|
47
|
-
lib/ruhoh/parsers/pages.rb
|
48
|
-
lib/ruhoh/parsers/partials.rb
|
49
|
-
lib/ruhoh/parsers/payload.rb
|
50
|
-
lib/ruhoh/parsers/posts.rb
|
51
|
-
lib/ruhoh/parsers/routes.rb
|
52
|
-
lib/ruhoh/parsers/scaffolds.rb
|
53
|
-
lib/ruhoh/parsers/site.rb
|
54
|
-
lib/ruhoh/parsers/stylesheets.rb
|
55
|
-
lib/ruhoh/parsers/theme_config.rb
|
56
|
-
lib/ruhoh/parsers/widgets.rb
|
57
|
-
lib/ruhoh/paths.rb
|
58
|
-
lib/ruhoh/previewer.rb
|
59
|
-
lib/ruhoh/program.rb
|
60
|
-
lib/ruhoh/templaters/asset_helpers.rb
|
61
|
-
lib/ruhoh/templaters/base_helpers.rb
|
62
|
-
lib/ruhoh/templaters/helpers.rb
|
63
|
-
lib/ruhoh/templaters/rmustache.rb
|
64
|
-
lib/ruhoh/urls.rb
|
65
|
-
lib/ruhoh/utils.rb
|
66
|
-
lib/ruhoh/version.rb
|
67
|
-
lib/ruhoh/watch.rb
|
68
|
-
ruhoh.gemspec
|
69
|
-
spec/config_spec.rb
|
70
|
-
spec/db_spec.rb
|
71
|
-
spec/page_spec.rb
|
72
|
-
spec/parsers/layouts_spec.rb
|
73
|
-
spec/parsers/pages_spec.rb
|
74
|
-
spec/parsers/posts_spec.rb
|
75
|
-
spec/parsers/routes_spec.rb
|
76
|
-
spec/parsers/site_spec.rb
|
77
|
-
spec/setup_spec.rb
|
78
|
-
spec/spec_helper.rb
|
79
|
-
spec/support/shared_contexts.rb
|
80
|
-
system/dash.html
|
81
|
-
system/partials/categories_list.html
|
82
|
-
system/partials/pages_list.html
|
83
|
-
system/partials/posts_collate.html
|
84
|
-
system/partials/posts_list.html
|
85
|
-
system/partials/posts_summary.html
|
86
|
-
system/partials/tags_list.html
|
87
|
-
system/scaffolds/draft.html
|
88
|
-
system/scaffolds/layout.html
|
89
|
-
system/scaffolds/page.html
|
90
|
-
system/scaffolds/post.html
|
91
|
-
system/widgets/analytics/config.yml
|
92
|
-
system/widgets/analytics/layouts/getclicky.html
|
93
|
-
system/widgets/analytics/layouts/google.html
|
94
|
-
system/widgets/comments/config.yml
|
95
|
-
system/widgets/comments/layouts/disqus.html
|
96
|
-
system/widgets/comments/layouts/facebook.html
|
97
|
-
system/widgets/comments/layouts/intensedebate.html
|
98
|
-
system/widgets/comments/layouts/livefyre.html
|
99
|
-
system/widgets/google_prettify/config.yml
|
100
|
-
system/widgets/google_prettify/layouts/google_prettify.html
|
101
|
-
]
|
102
|
-
# = MANIFEST =
|
22
|
+
|
23
|
+
s.files = `git ls-files`.
|
24
|
+
split("\n").
|
25
|
+
sort.
|
26
|
+
reject { |file| file =~ /^(\.|rdoc|pkg|coverage)/ }
|
103
27
|
end
|
data/spec/spec_helper.rb
CHANGED
@@ -3,22 +3,23 @@ shared_context 'write_default_theme' do
|
|
3
3
|
Dir.mkdir SampleSitePath
|
4
4
|
theme = "twitter"
|
5
5
|
# Create base config.yml + base theme
|
6
|
-
File.open(File.join(SampleSitePath,
|
6
|
+
File.open(File.join(SampleSitePath, "config.yml"), "w+") { |file|
|
7
7
|
file.puts <<-TEXT
|
8
8
|
---
|
9
9
|
theme: '#{theme}'
|
10
10
|
---
|
11
11
|
TEXT
|
12
12
|
}
|
13
|
-
theme_dir = File.join(SampleSitePath,
|
13
|
+
theme_dir = File.join(SampleSitePath, theme)
|
14
14
|
FileUtils.makedirs theme_dir
|
15
15
|
end
|
16
16
|
end
|
17
17
|
|
18
18
|
shared_context 'default_setup' do
|
19
19
|
before(:each) do
|
20
|
-
Ruhoh.
|
21
|
-
|
22
|
-
|
20
|
+
@ruhoh = Ruhoh.new
|
21
|
+
@ruhoh.setup(:source => SampleSitePath)
|
22
|
+
@ruhoh.setup_paths
|
23
|
+
@ruhoh.setup_urls
|
23
24
|
end
|
24
25
|
end
|
@@ -101,6 +101,9 @@
|
|
101
101
|
ul.page-list li {
|
102
102
|
margin-bottom:3px;
|
103
103
|
}
|
104
|
+
ul.page-list li.draft {
|
105
|
+
background-color:#EEE;
|
106
|
+
}
|
104
107
|
ul.page-list li a{
|
105
108
|
display:block;
|
106
109
|
overflow:hidden;
|
@@ -127,62 +130,43 @@
|
|
127
130
|
</style>
|
128
131
|
</head>
|
129
132
|
<body>
|
130
|
-
<div id="wrapper">
|
131
|
-
|
132
|
-
<div id="nav-wrapper">
|
133
|
-
<ul id="nav">
|
134
|
-
<li><a href="#drafts" class="active">Drafts</a></li>
|
135
|
-
<li><a href="#public">Posts</a></li>
|
136
|
-
<li><a href="#pages">Pages</a></li>
|
137
|
-
</ul>
|
138
|
-
</div>
|
133
|
+
<div id="wrapper">
|
139
134
|
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
<br><span class="id">{{id}}</span></small>
|
148
|
-
</a>
|
149
|
-
</li>
|
150
|
-
{{/ db.posts.drafts?to_posts }}
|
151
|
-
</ul>
|
152
|
-
</div>
|
135
|
+
<div id="nav-wrapper">
|
136
|
+
<ul id="nav">
|
137
|
+
{{# page_collections }}
|
138
|
+
<li><a href="#{{ resource_name }}">{{ resource_name }}</a></li>
|
139
|
+
{{/ page_collections }}
|
140
|
+
</ul>
|
141
|
+
</div>
|
153
142
|
|
154
|
-
|
155
|
-
<
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
{{/posts}}
|
167
|
-
</ul>
|
168
|
-
</div>
|
143
|
+
{{# page_collections }}
|
144
|
+
<div id="{{ resource_name }}" class="page-pane">
|
145
|
+
<ul class="page-list">
|
146
|
+
{{# drafts }}
|
147
|
+
<li class="draft">
|
148
|
+
<a href="{{url}}">
|
149
|
+
<span class="title">{{title}}</span>
|
150
|
+
<span class="date">{{date}}</span>
|
151
|
+
<br><span class="id">{{id}}</span></small>
|
152
|
+
</a>
|
153
|
+
</li>
|
154
|
+
{{/ drafts }}
|
169
155
|
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
</
|
180
|
-
|
181
|
-
|
156
|
+
{{# all }}
|
157
|
+
<li>
|
158
|
+
<a href="{{url}}">
|
159
|
+
<span class="title">{{title}}</span>
|
160
|
+
<span class="date">{{date}}</span>
|
161
|
+
<br><span class="id">{{id}}</span></small>
|
162
|
+
</a>
|
163
|
+
</li>
|
164
|
+
{{/ all }}
|
165
|
+
</ul>
|
166
|
+
</div>
|
167
|
+
{{/ page_collections }}
|
182
168
|
</div>
|
183
169
|
|
184
|
-
</div>
|
185
|
-
|
186
170
|
<script>
|
187
171
|
// Tabs is a small script for showing/hiding the different page lists.
|
188
172
|
// This mostly likely only works in modern browsers but
|
@@ -208,6 +192,8 @@
|
|
208
192
|
var id = e.target.href.split('#')[1];
|
209
193
|
document.getElementById(id).style.display = 'block';
|
210
194
|
}, false)
|
195
|
+
|
196
|
+
Tabs.nav.children[0].children[0].click();
|
211
197
|
},
|
212
198
|
|
213
199
|
clearActive : function(){
|
File without changes
|
@@ -0,0 +1,28 @@
|
|
1
|
+
<div class="row-fluid">
|
2
|
+
<div class="span12">
|
3
|
+
{{#collection.paginator}}
|
4
|
+
<div class="{{ collection.resource_name}}">
|
5
|
+
<h3 class="title"><a href="{{url}}">{{title}}</a> <span class="date">{{ date }}</span></h3>
|
6
|
+
|
7
|
+
{{{ summary }}}
|
8
|
+
|
9
|
+
<div class="more">
|
10
|
+
<a href="{{url}}" class="btn btn-small">read more..</a>
|
11
|
+
</div>
|
12
|
+
</div>
|
13
|
+
{{/collection.paginator}}
|
14
|
+
|
15
|
+
<div class="pagination">
|
16
|
+
<ul>
|
17
|
+
{{#collection.paginator_navigation}}
|
18
|
+
{{#is_active_page}}
|
19
|
+
<li class="active"><a href="{{url}}">{{name}}</a></li>
|
20
|
+
{{/is_active_page}}
|
21
|
+
{{^is_active_page}}
|
22
|
+
<li><a href="{{url}}">{{name}}</a></li>
|
23
|
+
{{/is_active_page}}
|
24
|
+
{{/collection.paginator_navigation}}
|
25
|
+
</ul>
|
26
|
+
</div>
|
27
|
+
</div>
|
28
|
+
</div>
|
@@ -0,0 +1,25 @@
|
|
1
|
+
require 'sprockets'
|
2
|
+
module Ruhoh::Resources::Javascripts
|
3
|
+
class Compiler
|
4
|
+
include Ruhoh::Base::Compilable
|
5
|
+
|
6
|
+
def run
|
7
|
+
Ruhoh::Friend.say { cyan "Javascripts: (using sprockets)" }
|
8
|
+
env = Sprockets::Environment.new
|
9
|
+
env.logger = Logger.new(STDOUT)
|
10
|
+
@collection.paths.reverse.each do |h|
|
11
|
+
env.append_path(File.join(h["path"], @collection.resource_name))
|
12
|
+
end
|
13
|
+
|
14
|
+
compiled_path = Ruhoh::Utils.url_to_path(@collection.url_endpoint, @ruhoh.paths.compiled)
|
15
|
+
FileUtils.mkdir_p compiled_path
|
16
|
+
|
17
|
+
manifest = Sprockets::Manifest.new(env, compiled_path)
|
18
|
+
assets = @collection.files.values.map{ |p| p["id"] }
|
19
|
+
manifest.compile(assets)
|
20
|
+
|
21
|
+
# Update the stylesheet paths to the digest format:
|
22
|
+
@collection._cache.merge!(manifest.assets)
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
require 'sprockets'
|
2
|
+
module Ruhoh::Resources::Javascripts
|
3
|
+
class Previewer
|
4
|
+
extend Forwardable
|
5
|
+
|
6
|
+
def_instance_delegator :@environment, :call
|
7
|
+
|
8
|
+
def initialize(ruhoh)
|
9
|
+
environment = Sprockets::Environment.new
|
10
|
+
collection = ruhoh.collection('javascripts')
|
11
|
+
collection.paths.reverse.each do |path|
|
12
|
+
environment.append_path(path)
|
13
|
+
end
|
14
|
+
@environment = environment
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
require 'sprockets'
|
2
|
+
module Ruhoh::Resources::Stylesheets
|
3
|
+
class Compiler
|
4
|
+
include Ruhoh::Base::Compilable
|
5
|
+
|
6
|
+
def run
|
7
|
+
Ruhoh::Friend.say { cyan "Stylesheets: (using sprockets)" }
|
8
|
+
env = Sprockets::Environment.new
|
9
|
+
env.logger = Logger.new(STDOUT)
|
10
|
+
@collection.paths.reverse.each do |h|
|
11
|
+
env.append_path(File.join(h["path"], @collection.resource_name))
|
12
|
+
end
|
13
|
+
|
14
|
+
compiled_path = Ruhoh::Utils.url_to_path(@collection.url_endpoint, @ruhoh.paths.compiled)
|
15
|
+
FileUtils.mkdir_p compiled_path
|
16
|
+
|
17
|
+
manifest = Sprockets::Manifest.new(env, compiled_path)
|
18
|
+
assets = @collection.files.values.map{ |p| p["id"] }
|
19
|
+
puts assets.inspect
|
20
|
+
manifest.compile(assets)
|
21
|
+
|
22
|
+
# Update the stylesheet paths to the digest format:
|
23
|
+
@collection._cache.merge!(manifest.assets)
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
require 'sprockets'
|
2
|
+
module Ruhoh::Resources::Stylesheets
|
3
|
+
class Previewer
|
4
|
+
extend Forwardable
|
5
|
+
|
6
|
+
def_instance_delegator :@environment, :call
|
7
|
+
|
8
|
+
def initialize(ruhoh)
|
9
|
+
environment = Sprockets::Environment.new
|
10
|
+
collection = ruhoh.collection('stylesheets')
|
11
|
+
collection.paths.reverse.each do |path|
|
12
|
+
environment.append_path(path)
|
13
|
+
end
|
14
|
+
@environment = environment
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -1,6 +1,10 @@
|
|
1
|
+
---
|
2
|
+
site_id : 123
|
3
|
+
---
|
4
|
+
|
1
5
|
<script>
|
2
6
|
var clicky_site_ids = clicky_site_ids || [];
|
3
|
-
clicky_site_ids.push({{
|
7
|
+
clicky_site_ids.push({{ this_config.site_id }});
|
4
8
|
(function() {
|
5
9
|
var s = document.createElement('script');
|
6
10
|
s.type = 'text/javascript';
|
@@ -9,4 +13,4 @@ clicky_site_ids.push({{ config.getclicky.site_id }});
|
|
9
13
|
( document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0] ).appendChild( s );
|
10
14
|
})();
|
11
15
|
</script>
|
12
|
-
<noscript><p><img alt="Clicky" width="1" height="1" src="//in.getclicky.com/{{
|
16
|
+
<noscript><p><img alt="Clicky" width="1" height="1" src="//in.getclicky.com/{{ this_config.site_id }}ns.gif" /></p></noscript>
|
@@ -1,5 +1,9 @@
|
|
1
|
+
---
|
2
|
+
tracking_id : 'UA-123-12'
|
3
|
+
---
|
4
|
+
|
1
5
|
<script>
|
2
|
-
var _gaq=[['_setAccount','{{
|
6
|
+
var _gaq=[['_setAccount','{{ this_config.tracking_id }}'],['_trackPageview']];
|
3
7
|
(function(d,t){var g=d.createElement(t),s=d.getElementsByTagName(t)[0];
|
4
8
|
g.src=('https:'==location.protocol?'//ssl':'//www')+'.google-analytics.com/ga.js';
|
5
9
|
s.parentNode.insertBefore(g,s)}(document,'script'));
|
@@ -1,7 +1,11 @@
|
|
1
|
+
---
|
2
|
+
short_name : jekyllbootstrap # Change This!
|
3
|
+
---
|
4
|
+
|
1
5
|
<div id="disqus_thread"></div>
|
2
6
|
<script>
|
3
|
-
{{^production }}var disqus_developer = 1;{{/production}}
|
4
|
-
var disqus_shortname = '{{
|
7
|
+
{{^ env.production }}var disqus_developer = 1;{{/ env.production }}
|
8
|
+
var disqus_shortname = '{{ this_config.short_name }}'; // required: replace example with your forum shortname
|
5
9
|
/* * * DON'T EDIT BELOW THIS LINE * * */
|
6
10
|
(function() {
|
7
11
|
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
|