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
deployer@debian:~$ find /etc/apt/ -name '*.list' -printf "\n%p:\n" -exec cat {} \; | |
/etc/apt/sources.list: | |
# | |
# deb cdrom:[Debian GNU/Linux 6.0.6 _Squeeze_ - Official i386 xfce+lxde-CD Binary-1 20120929-15:56]/ squeeze main | |
deb cdrom:[Debian GNU/Linux 6.0.6 _Squeeze_ - Official i386 xfce+lxde-CD Binary-1 20120929-15:56]/ squeeze main | |
deb http://security.debian.org/ squeeze/updates main |
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
# ~/.bashrc: executed by bash(1) for non-login shells. | |
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) | |
# for examples | |
JAVA_HOME=/usr/lib/jvm/jdk1.6.0_33/bin | |
export JAVA_HOME | |
PATH=$PATH:$JAVA_HOME # Add JDK to PATH for scripting | |
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
posts = User.last.posts_feed(params.slice(:limit, :before)) | |
posts = V1::PostPresenter(posts) | |
class V1::PostPresenter < V1::BasePresenter | |
attr_accessor :model | |
def initialize(model) | |
self.model = model |
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
hey guys, I got stuck in this weird nginx/unicorn infinite loop. | |
I used capistrano to deploy, it happened before, I think it always happens when I have new migrations. | |
sudo service nginx restart #doesn't work | |
sudo reboot #this worked last time, I think it will work now too, but there's gotta be some other way, | |
any help is appreciated, thanks in advance | |
tail -f log/production.log |
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
describe "GET index" do | |
=begin | |
it "assigns all posts as @posts" do | |
get :index, {}, valid_session | |
assigns(:posts).should eq([@post]) | |
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
hey... | |
$("a.fade-out-and-slide-up").click(function() { | |
$(this).fadeOut('fast', function() { $(this).slideUp('slow'); }); | |
}); | |
I want this to have a smooth, sequential behavior (not parallel). | |
how can I? |
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 'spec_helper' | |
describe "Session" do | |
describe "GET /auth/facebook" do | |
it "with capybara: triggers callback and creates Bob Example" do | |
Fabricate(:school) | |
# I'm a guest | |
visit home_index_path |
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 'spec_helper' | |
describe 'Home' do | |
describe "GET /home/user" do | |
it "capybara: from login page until " do | |
Fabricate(:school) | |
# - creating user |
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
strange, I get this evil routing error in rspec, but the browser works fine | |
---------- | |
routes.rb | |
get "home/user_school/:token" => "home#user_school", as: 'home_user_school' | |