Skip to content

Instantly share code, notes, and snippets.

View renius's full-sized avatar

Антон Дьячук renius

View GitHub Profile
@renius
renius / gist:3293373
Last active October 8, 2015 06:38 — forked from the-teacher/gist:3103066
UBUNTU + RAILS
BUTTONS
gconftool-2 --set "/apps/metacity/general/button_layout" --type string "menu:minimize,maximize,close"
GNOME COMMANDER
sudo apt-get install gnome-commander -y
COMMON
sudo apt-get update
sudo apt-get install build-essential bison openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxslt1.1 libxslt1-dev libxml2 libxml2-dev libxslt-dev autoconf libc6-dev nodejs -y
@renius
renius / select2dropdown.js.coffee
Last active December 12, 2015 07:28
# Convert .bootstrap-select elements to Bootstrap Dropdown Group # Assumes jQuery and Bootstrap scripts already linked
#
# Convert .bootstrap-select elements to Bootstrap Dropdown Group
# Assumes jQuery and Bootstrap scripts already linked
# !!! require jQuery 1.7.2 - 1.8.3
#
# Expected markup:
# <select class="span1" id="car_engine_type" name="car[engine_type]" style="margin-left: 30px">
# <option value="">fuel</option>
# <option value="diesel">diesel</option>
# <option value="gasoline">gasoline</option>
upstream backend {
server 127.0.0.1:3000 fail_timeout=0;
}
server {
listen 80;
server_name mydomain.com;
root /path/to/project/public;
@renius
renius / app.css
Created August 17, 2013 09:09 — forked from niquola/app.css
.progress {
border: 1px solid #ddd;
width: 100px;
height: 10px;
}
.progress .bar {
background-color: #aae;
width: 10px;
height: 10px;
}
module FactoryGirl
module Syntax
module Methods
def find_or_create(name, attributes = {}, &block)
attributes = FactoryGirl.attributes_for(name).merge(attributes)
result =
FactoryGirl.
factory_by_name(name).
build_class.
@renius
renius / lol
Last active September 7, 2016 14:54
HASH =
{
"U6" => { "RTC" => "RFC"},
else: { "MAN" => "TFD"}
}
def build_status_code(telegram)
carrier = telegram.info['CarrierCode']
status = telegram.info['StatusCode']
@renius
renius / GIF-Screencast-OSX.md
Created September 7, 2016 16:55 — forked from davydovanton/GIF-Screencast-OSX.md
OS X Screencast to animated GIF

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application: