Skip to content
This repository has been archived by the owner on Dec 29, 2022. It is now read-only.

Commit

Permalink
Remove disqus. Make other parts optional. Add missing gem dependency.
Browse files Browse the repository at this point in the history
  • Loading branch information
GUI committed Oct 24, 2015
1 parent 6970e67 commit 48d3d43
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 37 deletions.
3 changes: 3 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ gem "rails-assets-parsleyjs", "~> 2.0.3"
# Icons
gem "rails-assets-fontawesome", "~> 4.1.0"

# JS runtime for execjs (used for asset minification).
gem "therubyracer", "~> 0.12.2"

group :development do
# Deployment
gem "capistrano", "~> 3.3.5"
Expand Down
9 changes: 0 additions & 9 deletions source/assets/stylesheets/_shared/_docs.scss
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
#disqus_thread {
border-top: 2px solid #ddd;
margin-top: 3em;
padding-top: 1em;
}

h2, h3 {
margin-top: 12px;
}
Expand Down Expand Up @@ -127,9 +121,6 @@ div.doc-example-url {
margin: 5px 0px;
}

#disqus_thread {
}

.highlight-code {
overflow: auto;
width: 100%;
Expand Down
18 changes: 10 additions & 8 deletions source/layouts/_analytics.erb
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
<% if(ENV["GOOGLE_ANALYTICS_TRACKING_ID"]) %>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');

ga('create', '<%= ENV["GOOGLE_ANALYTICS_TRACKING_ID"] %>', 'auto');
ga('send', 'pageview');
</script>
ga('create', '<%= ENV["GOOGLE_ANALYTICS_TRACKING_ID"] %>', 'auto');
ga('send', 'pageview');
</script>
<% end %>
16 changes: 0 additions & 16 deletions source/layouts/_disqus.erb

This file was deleted.

8 changes: 5 additions & 3 deletions source/layouts/_edit_me.erb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
<div style="text-align: center; font-style: italic; padding: 3em 0.5em 0em 0.5em;">
<a href="<%= ENV["GITHUB_REPO_URL"] %>/blob/master/source<%= current_page.source_file.gsub(current_page.app.source_dir, '') %>">Help Improve this Content</a>
</div>
<% if(ENV["GITHUB_REPO_URL"]) %>
<div style="text-align: center; font-style: italic; padding: 3em 0.5em 0em 0.5em;">
<a href="<%= ENV["GITHUB_REPO_URL"] %>/blob/master/source<%= current_page.source_file.gsub(current_page.app.source_dir, '') %>">Help Improve this Content</a>
</div>
<% end %>
1 change: 0 additions & 1 deletion source/layouts/layout.erb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
<body class="<%= page_classes %>">
<%= partial("layouts/header") %>
<%= yield %>
<%= partial("layouts/disqus") %>
<%= partial("layouts/edit_me") %>
<%= partial("layouts/footer") %>
</body>
Expand Down

0 comments on commit 48d3d43

Please sign in to comment.