Skip to content

Instantly share code, notes, and snippets.

Large Object Motions:
(
)
{
}
[[
[]
][
]]
[m
class Feature
include Mongoid::Document
include Mongoid::Timestamps
include Mongoid::Attributes::Dynamic
field :filename, type: String
field :title, type: String
field :description, type: String
field :tags, type: String
# mongo_template.rb
# remove unneeded defaults
run "rm public/index.html"
run "rm public/images/rails.png"
run "rm public/javascripts/controls.js"
run "rm public/javascripts/dragdrop.js"
run "rm public/javascripts/effects.js"
run "rm public/javascripts/prototype.js"
; A REPL-based, annotated Seesaw tutorial
; Please visit https://github.com/daveray/seesaw for more info
;
; This is a very basic intro to Seesaw, a Clojure UI toolkit. It covers
; Seesaw's basic features and philosophy, but only scratches the surface
; of what's available. It only assumes knowledge of Clojure. No Swing or
; Java experience is needed.
;
; This material was first presented in a talk at @CraftsmanGuild in
; Ann Arbor, MI.
StringLiterals:
Enabled: false
LineLength:
Max: 99
Encoding:
Enabled: false
HashSyntax:
Enabled: false
config.generators do |g|
g.test_framework :rspec, :fixture => false
g.view_specs false
g.helper_specs false
end
package eventfax.protocol
import scala.collection.jcl.TreeMap
import java.util.Date
import java.text.SimpleDateFormat
import java.text.DateFormat
import scala.collection.jcl.ArrayList
import scala.collection.mutable.Map
class HttpResponse(val pristine: Boolean) {
;; Set the starting position and width and height of Emacs Window
(add-to-list 'default-frame-alist '(left . 0))
(add-to-list 'default-frame-alist '(top . 0))
(add-to-list 'default-frame-alist '(height . 45))
(add-to-list 'default-frame-alist '(width . 175))
;; To get rid of Weird color escape sequences in Emacs.
;; Instruct Emacs to use emacs term-info not system term info
;; http://stackoverflow.com/questions/8918910/weird-character-zsh-in-emacs-terminal
(setq system-uses-terminfo nil)
(setq enh-ruby-program "/home/gnufied/.rbenv/versions/1.9.3-p448/bin/ruby")
(autoload 'enh-ruby-mode "enh-ruby-mode" "Major mode for ruby files" t)
(add-to-list 'auto-mode-alist '("\\.rb$" . enh-ruby-mode))
(add-to-list 'auto-mode-alist '("\\.rake$" . enh-ruby-mode))
(add-to-list 'auto-mode-alist '("Rakefile$" . enh-ruby-mode))
(add-to-list 'auto-mode-alist '("\\.gemspec$" . enh-ruby-mode))
(add-to-list 'auto-mode-alist '("\\.ru$" . enh-ruby-mode))
(add-to-list 'auto-mode-alist '("Gemfile$" . enh-ruby-mode))
(add-to-list 'interpreter-mode-alist '("ruby" . enh-ruby-mode))
configuration:
(require 'robe)
(add-hook 'enh-ruby-mode-hook 'robe-mode)
Usage:
I have noticed that when inf-ruby mode loads pry it just hangs because of
pry trying to be smart about determining terminal type. It is
not a problem with robe per se, but the fact that pry is unusable from