Skip to content

Instantly share code, notes, and snippets.

View dennismonsewicz's full-sized avatar

Dennis Monsewicz dennismonsewicz

View GitHub Profile
import Backbone from 'backbone';
import _ from 'lodash';
const html = `<div class="book"><%= title %> :: <%= pages %></div>`;
const Book = Backbone.Model.extend({
defaults: {
title: null,
pages: 0,
},
# custom_plan.rb
require 'zeus/rails'
class CustomPlan < Zeus::Rails
def server
require 'thin/server'
server = ::Thin::Server.new(::Rails.application, 3001)
server.start
end
@dennismonsewicz
dennismonsewicz / gist:2319588
Created April 6, 2012 13:06
Easy way to run delete_all on all database tables when running a seed file
Dir["../app/models/*.rb"].each do |file|
File.basename(file, ".rb").capitalize.delete_all
end