Skip to content

Instantly share code, notes, and snippets.

View SergeyKishenin's full-sized avatar
🥴

Sergey Kishenin SergeyKishenin

🥴
View GitHub Profile
class User < ActiveRecord::Base
# Include default devise modules. Others available are:
# :token_authenticatable, :confirmable, :lockable and :timeoutable
devise :database_authenticatable , :registerable, :recoverable, :rememberable, :trackable, :validatable
devise :omniauthable#, :omniauth_providers => [:facebook]
devise :encryptable, :encryptor => :custom_encryptor
# Devise: Setup accessible (or protected) attributes for your model
attr_accessible :email, :password, :password_confirmation, :remember_me
@zhengjia
zhengjia / capybara cheat sheet
Created June 7, 2010 01:35
capybara cheat sheet
=Navigating=
visit('/projects')
visit(post_comments_path(post))
=Clicking links and buttons=
click_link('id-of-link')
click_link('Link Text')
click_button('Save')
click('Link Text') # Click either a link or a button
click('Button Value')
package :imagemagick do
description "ImageMagick"
version '6.5.4-10'
source "ftp://ftp.fifi.org/pub/ImageMagick/ImageMagick-#{version}.tar.gz" do
prefix '/usr'
disable 'static'
enable 'shared'
with %w(modules quantum-depth=8)
without %w(perl magick-plus-plus)