Skip to content

Instantly share code, notes, and snippets.

View keikun17's full-sized avatar

Cakey | Buddy Magsipoc keikun17

View GitHub Profile
@keikun17
keikun17 / gist:5054019
Last active December 14, 2015 07:58
Dorama chekurisuto

Buddy's Guide to Tech Drama

I. vim vs emacs

II. ruby vs python

III. coffeescript vs javascript

  • Stage 1 : Damage Control
    • Person A : CS sucks, useless abstraction. QQ.
    • Person B : CS is a tool, preference blabla!
    • Person A : CS still suck!
@keikun17
keikun17 / gist:5027688
Last active December 14, 2015 04:19
jruby 1.6.8 + gem 2.0.0 problem with 'gem install'
$ jruby -v
jruby 1.6.8 (ruby-1.8.7-p357) (2012-09-18 1772b40) (Java HotSpot(TM) 64-Bit Server VM 1.7.0_02) [linux-amd64-java]
$ jruby -S gem --version
2.0.0
$ jruby -S gem install jruby-openssl
JRuby limited openssl loaded. http://jruby.org/openssl
gem install jruby-openssl for full support.
ERROR: Loading command: install (LoadError)
@keikun17
keikun17 / gist:4983271
Created February 19, 2013 05:11
Razer blade specs
Processor
   Intel® Core™ i7
   Quad Core Processor with Hyper-Threading
   CPU: 2.2GHz (Base) / 3.2GHz (Turbo)
Chipset
   Intel® HM77 Express Chipset
@keikun17
keikun17 / gist:4133510
Created November 23, 2012 01:00
Lean Passing

Subject name : Differential Equations

Estimated # of quizzes this term : 3

Estimated # of HWs this term : 4

Passing rate : 70

def tag_list=(tags_string, current_user)
self.taggings.destroy_all
tag_names = tags_string.split(",").collect{|s| s.strip.downcase}.uniq
tag_names.each do |tag_name|
tag = current_user.tags.find_or_create_by_name(tag_name)
tagging = self.taggings.new # <= code smell
tagging.tag_id = tag.id # <= code smell
end
@keikun17
keikun17 / toggle powerline solarized-light
Created September 17, 2012 04:45
Toggle Powerline (Solarized light)
" ======== Glorious background toggling ========
" requires solarizedLightLC theme from : https://github.com/pearofducks/vim-powerline/blob/develop/autoload/Powerline/Colorschemes/solarizedLightLC.vim
" put this theme under this directory : ~/.yadr/vim/bundle/skwp-vim-powerline/autoload/Powerline/Colorschemes/
let g:powerline_dark_theme = 'skwp'
let g:powerline_light_theme = 'solarizedLightLC'
function! EmoModeOn()
set background=dark
let g:Powerline_colorscheme = g:powerline_dark_theme
endfunction
// a bit of context here, obj will be an input field object that is rendered by an 'in-place' edit feature
obj = $("#environment_233 input").first()
// [<input id="regression_test_environment[name]" name="regression_test_environment[name]" style type="text" value="iii">]
obj
// [<input id="regression_test_environment[name]" name="regression_test_environment[name]" style type="text" value="iii">]
obj.attr('name')
// "regression_test_environment[name]"