Skip to content

Instantly share code, notes, and snippets.

View Vetal4eg's full-sized avatar
👌
getting the right things done

Vitaliy Esaulenko Vetal4eg

👌
getting the right things done
View GitHub Profile
@ankane
ankane / README.md
Last active December 14, 2015 03:39 — forked from panthomakos/benchmark.rb

Benchmark Bundler

Because loading gems can take longer than you think

Now available as a gem - get it here

@shtirlic
shtirlic / dio.rb
Created April 15, 2013 19:48
Digital Ocean CLI on ruby Place it in ~/bin/dio
#!/usr/bin/env ruby
require 'httparty'
require 'ostruct'
require "thor"
CLIENT_ID = ENV['DIGITAL_OCEAN_CLIENT_ID']
API_ID = ENV['DIGITAL_OCEAN_API_ID']
@komasaru
komasaru / test_xml.rb
Last active February 6, 2016 11:38
Ruby script to do tests of parsing xml with Nokogiri, Hpricot parsers.
# **************************************
# XML パーステスト
# **************************************
#
require 'hpricot'
require 'nokogiri'
class TestXml
FILE_XML = "sitemap.xml"
N = 100
@Paprikas
Paprikas / Morpher usage example.rb
Last active May 26, 2016 20:09
Model for work with http://morpher.ru/ service
Usage example:
>> text = Morpher.new('Большой город')
{:Р=>"Большого города", :Д=>"Большому городу", :В=>"Большой город", :Т=>"Большим городом", :П=>"Большом городе", :П_о=>"о Большом городе", :род=>"Мужской", :множественное=>{:И=>"Большие города", :Р=>"Больших городов", :Д=>"Большим городам", :В=>"Большие города", :Т=>"Большими городами", :П=>"Больших городах", :П_о=>"о Больших городах"}, :где=>"в Большом городе", :куда=>"в Большой город", :откуда=>"из Большого города"}
>> text.singular('Д')
"Большому городу"
>> text.plural('Д')

I upgraded to El Capitan, with Homebrew & Ruby, and this is how I did it flawlessly.

... and Xcode and Java, etc.

Prepare

If you don't already have homebrew installed, do that first, so you don't have to deal with SIP issues. Install all Software Updates available in the Apple Menu, up to and including El Capitan.

Hardware

@w495
w495 / python-style-decorators-in-erlang.md
Created June 12, 2012 18:31
Декораторы в Erlang

Перевод статьи: http://niki.code-karma.com/2011/06/python-style-decorators-in-erlang/

Введение

Алан Перлис однажды сказал, «Не стоит изучать язык, который не меняет вашего представления о программировании.» Мои любимые языки Erlang, Python и C++ (а еще Lua, но сейчас Python более востребован на рынке). Я люблю их за разное, и все они имеют совершенно разные сильные и слабые стороны и особенности.

@davydovanton
davydovanton / GIF-Screencast-OSX.md
Created August 21, 2016 15:06 — forked from dergachev/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:

@matthutchinson
matthutchinson / your-app.dev
Created June 20, 2013 13:38
your-app.dev
server {
listen 443 ssl;
server_name your-app.dev;
root /path/to/your-app/public;
index index.html index.htm;
### SSL log files ###
access_log logs/your-app.dev-ssl-access.log;
error_log logs/your-app.dev-ssl-error.log;
@arestov
arestov / Тезисы
Last active April 27, 2017 06:32
Декларативность. Лаконичный и оптимизируемый код
Декларативность. Лаконичный и оптимизируемый код
Разделение кода сложных состояний на 3 части позволяет сильно уменьшить сложность
и объем кода (за счёт автоматизации кода, актуализирующего эти состояния,
при изменении других состояний), а также реализовывать оптимизации на системном уровне.
1) Декларативное описание того как используется результат (зачем вы что-то делаете, целеполагание)
2) Декларативное описание от каких состояний зависит результат (что нужно чтобы выполнить задачу)
3) Способ вычисления результата (как распорядится ингридиентами, чтобы получить необходимое)