Skip to content

Instantly share code, notes, and snippets.

View yumitsu's full-sized avatar
🐢
I LIEK TURTLES

Alex Zinchenko yumitsu

🐢
I LIEK TURTLES
  • St. Petersburg, Russia
View GitHub Profile
@yumitsu
yumitsu / gist:2000140
Created March 8, 2012 10:15
Rake::CLI in CoffeeScript
Namespaces =
names: []
descriptions: []
tasks: []
injectMethods: (ins) ->
nspaces = @
ins.fqn = ->
@_nameChain().join ':'
@yumitsu
yumitsu / rspec_cheat_sheet.rd
Created March 24, 2012 05:16 — forked from byplayer/rspec_cheat_sheet.rd
rspec cheat sheet
INSTALL
=======
$ gem install rspec
RSPEC-RAILS
===========
RAILS-3
=======
@yumitsu
yumitsu / wait_until.rb
Created March 24, 2012 06:45 — forked from metaskills/wait_until.rb
Never sleep() using Capybara!
# Have you ever had to sleep() in Capybara-WebKit to wait for AJAX and/or CSS animations?
describe 'Modal' do
should 'display login errors' do
visit root_path
click_link 'My HomeMarks'
within '#login_area' do
fill_in 'email', with: 'will@not.work'
fill_in 'password', with: 'test'
@yumitsu
yumitsu / gist:3782934
Created September 25, 2012 16:24
jQuery scroller, like bootstrap scrollspy
$(document).ready(function(){
var lastId, topMenu = $("#navbar-scroll"),
topMenuHeight = topMenu.outerHeight() + 150,
menuItems = topMenu.find("a"),
scrollItems = menuItems.map(function() {
var item = $($(this).attr("href"));
if (item.length) {
return item;
}
});
@yumitsu
yumitsu / disable-werror.patch
Last active December 14, 2015 02:39
Patch to compile ruby 1.9.3 with Clang on Mac OSX 10.8 (https://bugs.ruby-lang.org/issues/7830)
diff --git a/configure.in b/configure.in
index 732dd5d..8f5b364 100644
--- a/configure.in
+++ b/configure.in
@@ -172,6 +172,7 @@ RUBY_PROGRAM_VERSION=`sed -n 's/^#define RUBY_VERSION "\(.*\)"/\1/p' $srcdir/ver
AC_SUBST(RUBY_PROGRAM_VERSION)
RUBY_RELEASE_DATE=`sed -n 's/^#define RUBY_RELEASE_DATE "\(.*\)"/\1/p' $srcdir/version.h`
AC_SUBST(RUBY_RELEASE_DATE)
+RUBY_PATCHLEVEL=`sed -n 's/^#define RUBY_PATCHLEVEL //p' $srcdir/version.h`
AC_DEFINE(CANONICALIZATION_FOR_MATHN)
@yumitsu
yumitsu / gist:5015386
Last active December 14, 2015 02:39
Ruby 1.9.3 RVM installation with railsexpress patchset and patch for Clang compatibility.
#!/bin/bash
rvm get head
rvm install 1.9.3-p385 --with-gcc=clang --patch http://bit.ly/dwpatch,railsexpress -C --disable-werror
@yumitsu
yumitsu / jquery-cookie.coffee
Created October 8, 2013 08:29
jQuery.cookie method

MacOS

Download from here:

http://d.pr/f/QE3d

MD5: 59bab8f71f8c096cd3f72cd73851515d

Rename it to: Sublime Text

Make it executable with: chmod u+x Sublime\ Text

@yumitsu
yumitsu / gist:ec0c8f1f03dbc94eed8c
Created August 29, 2014 09:22
ST3 build 3065, Linux x64 - licenses

These licenses will be valid after sublime_text patching:

- BEGIN License -
Love
Unlimited user license
EA7E-8441
918381ACA844A0379CCAC729059720A4
BC9D409098618744BB45FF23E67568DB
82B926D92157127DB3B4054834D0477F
@yumitsu
yumitsu / SassMeister-input.scss
Created August 30, 2014 19:10
Generated by SassMeister.com.
// ----
// Sass (v3.4.1)
// Compass (v1.0.1)
// Breakpoint (v2.5.0)
// ----
@import "compass";
@import "memo";
@import "breakpoint";