Skip to content

Instantly share code, notes, and snippets.

View anildigital's full-sized avatar
:octocat:

Anil Wadghule anildigital

:octocat:
View GitHub Profile
@ewindisch
ewindisch / gist:8959919
Created February 12, 2014 17:09
Remove docker images that aren't visible in 'docker images' (the images that only appear with 'images -a')
docker rmi $(comm -3 <(docker images -q | sort) <(docker images -q -a | sort) | sed 's/\t//')
@toch
toch / operators.md
Created March 14, 2014 08:07
Ruby Punctuations or a list of names of operators and other cabalistic punctuation
Operator Name
=> hashrocket
<=> spaceship
=== threequals
~> twiddlewalka
-> stabby lambda
@ spiral
* splat
~ tidle
anonymous
anonymous / check_emacs.sh
Created December 29, 2009 02:42
emacs -q --eval '(condition-case err (progn (load "~/.emacs") (kill-emacs 0)) (error (kill-emacs 1)))'
# Source http://groups.google.com/group/gnu.emacs.help/browse_thread/thread/bed5b2bd8b237f5a?pli=1
This is an example of using RVM's Project .rvmrc file
to have it automatically bootstrap your environment, including bundler.
This could be further expanded to do anything you require :)
The important thing to remember is that the purpose of these files is
to allow you to very easily have your 'project context' (aka 'environment')
loaded automatically for you when you enter the project in the shell (cd).
You can generate the .rvmrc file below by running:
(add-to-list 'load-path "~/.emacs.d/")
(require 'rainbow-parens)
;; clojure-mode
(add-to-list 'load-path "~/Projekt/clojure-mode")
(require 'clojure-mode)
;; swank-clojure
(require 'assoc)
#!/bin/bash
echo -e "tell application \"Quicksilver\"\nshow large type \"$1\"\nend tell" | osascript
%w|rubygems sinatra|.each{|_|require _}
%w|gem load|.each{|_| send _, 'kitty'}
(k=Kitty).send *%w(define_method print) do |*a| a.join end
get "/" do content_type "text/plain" and k.new.random_kitty end
# gem install kitty
# ruby kitty_server.rb &
# curl http://localhost:4567
require 'java'
20_000.times do
Class.new do
include java.util.Comparator
end.new
end
@wycats
wycats / gist:639657
Created October 22, 2010 00:09 — forked from evanphx/gist:639646
require 'rubygems'
require 'benchmark'
require 'erb'
require 'erubis'
require 'bundler'
#gem 'haml', '3.0.21'
# gem 'haml', '3.1.0.alpha.14'
require 'haml'
export RUBY_HEAP_MIN_SLOTS=1000000
export RUBY_HEAP_SLOTS_INCREMENT=1000000
export RUBY_HEAP_SLOTS_GROWTH_FACTOR=1
export RUBY_GC_MALLOC_LIMIT=1000000000
export RUBY_HEAP_FREE_MIN=500000