This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module CarrierWave | |
module FFMPEG | |
extend ActiveSupport::Concern | |
module ClassMethods | |
def faststart | |
process :faststart => true | |
end | |
def transcode options |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace :assets do | |
task :precompile, :roles => :web, :except => { :no_release => true } do | |
if capture("diff -r #{latest_release}/app/assets/ #{current_release}/app/assets/ | wc -l").to_i > 0 | |
run %Q{cd #{current_release} && #{rake} RAILS_ENV=#{rails_env} #{asset_env} assets:precompile} | |
else | |
logger.info "Skipping asset pre-compilation because there were no asset changes" | |
end | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# standard capistrano config goes here.... | |
# Prettify output to console | |
logger.level = Capistrano::Logger::IMPORTANT | |
STDOUT.sync | |
before "deploy:web:disable" do print "\e[34m-->\e[0m Put maintenance screen......."; end | |
after "deploy:web:disable" do puts "[\e[32m✓\e[0m]"; end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Support for Rspec / Capybara subdomain integration testing | |
# Make sure this file is required by spec_helper.rb | |
# | |
# Sample subdomain test: | |
# it "should test subdomain" do | |
# switch_to_subdomain("mysubdomain") | |
# visit root_path | |
# end | |
DEFAULT_HOST = "lvh.me" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ruby | |
принципиальное различие скриптовых и “обычных” языков | |
3 принципа ООП | |
реализация множественного наследования в ruby | |
duck typing | |
многопоточность в ruby | |
Rails | |
что такое MVC и зачем это нужно | |
локига в контроллере, должна ли быть и почему | |
синхронные и асинхронные операции — предложить варианты решения |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class Sphinx < Formula | |
url 'https://s3-eu-west-1.amazonaws.com/rnaveiras-software/sphinx-0.9.9.tar.gz' | |
homepage 'http://www.sphinxsearch.com' | |
sha1 '8c739b96d756a50972c27c7004488b55d7458015' | |
depends_on 'homebrew/dupes/apple-gcc42' | |
resource 'stemmer' do |