Skip to content

Instantly share code, notes, and snippets.

View travisdmathis's full-sized avatar
🏠
Working from home

Travis Mathis travisdmathis

🏠
Working from home
View GitHub Profile
var array = process.argv;
var arrayLength = array.length;
for (var i = 2; i < arrayLength; i++) {
var a = process.argv[i];
var total = 0;
$.each(a,function() {
total += this;
});
}
body {
background: url(bg.jpg) no-repeat center center fixed;
-webkibt-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
.spin {
position: relative;
height: 70px;
width: 70px;
border-radius: 50%;
border:dashed 5px white;
background-image:url(small_logo_icon.png);
-webkit-animation-name: spin;
-webkit-animation-duration: 1.5s;
-webkit-animation-iteration-count: infinite;
<% if flash[:notice] %>
<div class="alert alert-block">
<button type="button" class="close" data-dismiss=":notice">&times;</button>
<%= flash[:notice] %></p>
</div>
<% end %>
2013-11-14T23:28:25.897901+00:00 heroku[router]: at=info method=GET path=/assets/application.css host=limitless-dawn-3085.herokuapp.com fwd="69.54.5.98" dyno=web.1 connect=1ms service=6ms status=404 bytes=1351
2013-11-14T23:30:18.470832+00:00 app[web.1]: Started GET "/blog" for 69.54.5.98 at 2013-11-14 23:30:18 +0000
2013-11-14T23:30:18.470832+00:00 app[web.1]: Started GET "/blog" for 69.54.5.98 at 2013-11-14 23:30:18 +0000
2013-11-14T23:30:18.472108+00:00 app[web.1]: Processing by PostsController#index as HTML
2013-11-14T23:30:18.472146+00:00 app[web.1]: Processing by PostsController#index as HTML
2013-11-14T23:30:18.511935+00:00 app[web.1]: Completed 404 Not Found in 40ms
2013-11-14T23:30:18.514208+00:00 app[web.1]:
2013-11-14T23:30:18.511935+00:00 app[web.1]: Completed 404 Not Found in 40ms
2013-11-14T23:30:18.514208+00:00 app[web.1]:
2013-11-14T23:30:18.514208+00:00 app[web.1]: ActiveRecord::RecordNotFound (ActiveRecord::RecordNotFound):
2013-11-14T22:44:42.989330+00:00 app[web.1]: F, [2013-11-14T22:44:42.983181 #2] FATAL -- :
2013-11-14T22:44:42.989330+00:00 app[web.1]: ActionController::RoutingError (No route matches [GET] "/assets/application-4804ea275189d0fb32145d6dc1d312ef.css"):
2013-11-14T22:44:42.988848+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/sendfile.rb:112:in `call'
2013-11-14T22:44:42.988848+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/railties-4.0.1/lib/rails/engine.rb:511:in `call'
2013-11-14T22:44:42.988848+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/railties-4.0.1/lib/rails/application.rb:97:in `call'
2013-11-14T22:44:42.988848+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/lock.rb:17:in `call'
2013-11-14T22:44:42.987425+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/rack-1.5.2/lib/rack/runtime.rb:17:in `call'
2013-11-14T22:44:42.986440+00:00 app[web.1]: F, [2013-11-14T22:41:58.579062 #2] FATAL -- :
2013-11-14T22:44:42.987425+00:00 app[web.1]: vendor/bundle
<% ActsAsTaggableOn::Tagging.find_all_by_context("tags").each do |tagging| %>
<%= link_to tagging.tag, tag_path(tagging.tag), :class => "btn btn-success btn-lg" %>
<% end %>
Output:
localhost/tags/1
Desired Output:
localhost/tags/TagName
@travisdmathis
travisdmathis / categories show.html.erb
Last active December 28, 2015 06:29
Blog, w/ Categories using Categorization
<p id="notice"><%= notice %></p>
<p>
<strong>Name:</strong>
<%= @category.name %>
</p>
<%= link_to 'Edit', edit_category_path(@category) %> |
<%= link_to 'Back', categories_path %>
<% @recent_posts.each_with_index do |post| %>
<li class="list-group-item">
<% @title = post.title %>
<%= link_to @title, :action => "show", :id => post.id %>
</li>
<% end %>
root@bamt-miner:/opt/miners/cgminer# cat /etc/bamt/bamt.conf
# Big A Miner Thing configuration
# /etc/bamt/bamt.conf
#
# When done editing, restart mining to make changes here take effect
# If you're just setting up BAMT, be sure to edit pools as well.
#
# As of 0.5, many less common options have been removed from this
# default config to make it easier on the noobs.
#