This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ./configure --with-features=huge --enable-cscope --enable-pythoninterp --enable-rubyinterp --enable-perlinterp --enable-gui=macvim --with-mac-arch=intel --enable-multibyte --enable-clipboard=yes --enable-xterm_clipboard=yes |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(function(){ | |
| if ("placeholder" in document.createElement( "input" )){ return } | |
| $('input[placeholder]').each(function(){ | |
| $(this).val($(this).attr('placeholder')).css('color', '#999') | |
| }).focus(function(){ | |
| var placeholder = $(this).attr('placeholder') | |
| $(this).val( placeholder == $(this).val() || $(this).val() == '' ? '' : $(this).val() ).css('color', '#333') | |
| }).blur(function(){ | |
| var placeholder = $(this).attr('placeholder') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| input[type="checkbox"] { | |
| -webkit-transform: scale(1.2, 1.2); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # script/server with Rails 3 support | |
| ss() { | |
| if [ -f ./script/rails ]; then | |
| ./script/rails server $@ | |
| else | |
| ./script/server $@ | |
| fi | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (($) -> | |
| default_options = | |
| color: 'red' | |
| $.fn.samplePlugin = (options = default_options) -> | |
| hello() | |
| @each -> | |
| $(this).css | |
| background: options.color |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # thanks to cmer for this | |
| if Rails.env.development? | |
| Rails.application.assets.logger = Logger.new('/dev/null') | |
| Rails::Rack::Logger.class_eval do | |
| def call_with_quiet_assets(env) | |
| previous_level = Rails.logger.level | |
| Rails.logger.level = Logger::ERROR if env['PATH_INFO'].index("/assets/") == 0 | |
| call_without_quiet_assets(env).tap do | |
| Rails.logger.level = previous_level | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "rubygems" | |
| require "awesome_print" | |
| Pry.print = proc { |output, value| output.puts value.ai } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| set nocompatible " no more legacy | |
| set laststatus=2 " show status lines 2 lines up so I see it | |
| " Vundle specifics | |
| set rtp+=~/.vim/bundle/vundle | |
| call vundle#rc() | |
| Bundle 'gmarik/vundle' | |
| " Bundle 'less.vim' | |
| Bundle 'groenewege/vim-less' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # encoding: UTF-8 | |
| # | |
| # I realized objects were hard to grasp | |
| # You already understood the building blocks of programs(String, Fixnumb, Array, Hash) | |
| # | |
| # Look at the following to see what you can learn: | |
| s1 = 'String is an object' | |
| s2 = String.new('String is an object') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby -w | |
| # SETUP: | |
| # (assumes ~/bin/ is in your path) | |
| # cp colorize.rb ~/bin/colorize | |
| # chmod +x ~/bin/colorize | |
| # USAGE: | |
| # tail -f log/development.log | colorize | |
| class String |