Skip to content

Instantly share code, notes, and snippets.

View ck3g's full-sized avatar
👨‍💻
Studying

Vitali Tatarintev ck3g

👨‍💻
Studying
View GitHub Profile
@ck3g
ck3g / ruby.txt
Created May 9, 2013 06:14
Ruby in oh my zsh style
____ __ __ / /_ __ __
/ __// / / // __ \/ / / /
/ / / /_/ // /_/ / /_/ /
/_/ \____//_____/\__, /
/____/
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" RUNNING TESTS
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
map <leader>t :call RunTestFile()<cr>
map <leader>T :call RunNearestTest()<cr>
" map <leader>a :call RunTests('')<cr>
map <leader>c :w\|:!script/features<cr>
map <leader>w :w\|:!script/features --profile wip<cr>
function! RunTestFile(...)
@ck3g
ck3g / 1.rb
Last active December 14, 2015 14:18
scope :masseurs_with_name, ->(name) {
includes(:users).where('users.first_name like :name OR users.last_name like :name', name: "%#{name}%" )
}
@ck3g
ck3g / authentication.rb
Created December 12, 2012 09:14
OmniAuth
class Authentication < ActiveRecord::Base
belongs_to :user
attr_accessible :provider, :uid, :user_id
validates :provider, :uid, presence: true
end
@ck3g
ck3g / autocomplite.css.scss
Last active May 29, 2020 18:02
Twitter bootstrap + rails3-jquery-autocomplete gem styles
ul.ui-autocomplete {
margin-top: 2px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
position: absolute;
top: 100%;
left: 0;
z-index: 1000;
@ck3g
ck3g / Gemfile
Last active October 12, 2015 05:08
default environment
source 'https://rubygems.org'
gem 'rails', '4.1.1'
gem 'pg'
gem 'sass-rails', '~> 4.0.3'
gem 'uglifier', '>= 1.3.0'
gem 'coffee-rails', '~> 4.0.0'
# See https://github.com/sstephenson/execjs#readme for more supported runtimes
@ck3g
ck3g / proxies.rb
Last active October 20, 2018 15:23
Proxies
PROXIES = %W(
118.97.208.194:3128
118.97.247.107:3128
118.97.211.5:3128
175.136.226.87:3128
200.35.90.38:3128
95.70.208.245:8080
120.203.214.182:83