Skip to content

Instantly share code, notes, and snippets.

View Lightpower's full-sized avatar

Vitalii Bezkrovnyi Lightpower

View GitHub Profile
@Lightpower
Lightpower / gist:758bc8e314312e6306e6
Created November 9, 2014 16:20
apt-get update log
В кэше http://dl.google.com stable Release.gpg
Игн http://extras.ubuntu.com oneiric Release.gpg
Игн http://ua.archive.ubuntu.com oneiric Release.gpg
Игн http://ua.archive.ubuntu.com oneiric Release
Игн http://ua.archive.ubuntu.com oneiric/main Sources/DiffIndex
Игн http://ua.archive.ubuntu.com oneiric/restricted Sources/DiffIndex
Игн http://ua.archive.ubuntu.com oneiric/universe Sources/DiffIndex
Игн http://ua.archive.ubuntu.com oneiric/multiverse Sources/DiffIndex
Игн http://ua.archive.ubuntu.com oneiric/main i386 Packages/DiffIndex
Игн http://ua.archive.ubuntu.com oneiric/restricted i386 Packages/DiffIndex
[46, 55] in /Users/bva/work/fw2-users-and-groups-api/db/seeds.rb
46
47 puts "Created client '#{mobile_client.display_name}' with ID '#{mobile_client.client_id}' and secret '#{mobile_client.secret}' (scopes are '#{mobile_client.scope.join("', '")}')"
48
49 debugger
50
=> 51 user_confirmed = FactoryGirl.create(:user)
52 user_unconfirmed = FactoryGirl.create(:user, confirmed_at: nil, confirmation_token: 'Confirm-me')
53
54 puts "Confirmed user: #{user_confirmed.email}:demodemo1234"
@Lightpower
Lightpower / gist:6027664
Last active December 19, 2015 22:29
Interface
require "interface"
DuckInterface = interface {
required_methods :walk, :swim, :quack
}
class Duck
def walk
puts 'Duck walks'
end
@Lightpower
Lightpower / gist:5347055
Created April 9, 2013 16:14
config/deploy.rb
require 'mina/bundler'
require 'mina/rails'
require 'mina/git'
# require 'mina/rbenv' # for rbenv support. (http://rbenv.org)
# require 'mina/rvm' # for rvm support. (http://rvm.io)
# Basic settings:
# domain - The hostname to SSH to.
# deploy_to - Path to deploy into.
# repository - Git repo to clone from. (needed by mina/git)
bva@bva-X51L:~/work/performance_tests/sinatra-test$ ab -n 1000 -c 10 -t 8 0.0.0.0:3000/tests
This is ApacheBench, Version 2.3 <$Revision: 655654 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking 0.0.0.0 (be patient)
Finished 171 requests
Server Software: thin