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
class Message < ActiveRecord::Base | |
belongs_to :sender, :class_name => "User" | |
belongs_to :receiver, :class_name => "User" | |
validates_presence_of :body | |
before_validation_on_create :set_read | |
def set_read | |
self.read = false |
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
# == Schema Information | |
# Schema version: 20090222005710 | |
# | |
# Table name: users | |
# | |
# id :integer(4) not null, primary key | |
# login :string(40) | |
# first_name :string(100) | |
# last_name :string(100) | |
# email :string(100) |
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
>> user1 = User.first | |
User Load (0.3ms) SELECT * FROM `users` LIMIT 1 | |
User Columns (1.7ms) SHOW FIELDS FROM `users` | |
=> #<User id: 1, login: "imownbey", first_name: nil, last_name: nil, email: "[email protected]", crypted_password: "855e0c5f4b94b17bde30631bde6c000af0bf1b70", salt: "68e2008908516c79514629a803f97a382e19890f", created_at: "2009-03-15 02:07:18", updated_at: "2009-03-15 02:07:59", remember_token: nil, remember_token_expires_at: nil, city_id: 76427, avatar_file_name: nil, avatar_content: nil, avatar_file_size: nil, sex: nil, status: nil, occupation: nil, birthday: nil> | |
>> user2 = User.last | |
User Load (0.4ms) SELECT * FROM `users` ORDER BY users.id DESC LIMIT 1 | |
=> #<User id: 4, login: "iojdjf", first_name: "fdaojs", last_name: "oifjdoajfd", email: "[email protected]", crypted_password: "51df6a1bcba81a48bdb2468cdd02ae4fc5aca7bf", salt: "598f03e922f117fdded8d92977dbcbaff00d39d9", created_at: "2009-03-15 22:44:19", updated_at: "2009-03-15 22:44:19", remember_token: nil, remember_token_ |
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
<VirtualHost *:80> | |
ServerName www.example.com | |
ServerAlias example.com dev.example.com | |
DocumentRoot /path/ | |
RewriteEngine On | |
RewriteCond %{HTTP_HOST} ^(dev.)?example.com | |
RewriteRule (.*) http://www.example.com/$1 [R=301,L] | |
</VirtualHost> |
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
[~/src/rip] master $ integrity launch | |
/Users/imownbey/.rip/active/lib/integrity: Is a directory - /Users/imownbey/.rip/active/lib/integrity (Errno::EISDIR) | |
from /usr/local/bin/integrity:19:in `load' | |
from /usr/local/bin/integrity:19 |
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
[~] $ rip install haml | |
Searching gems.github.com for haml... | |
ERROR: Could not find haml in any repository | |
Searching gems.rubyforge.org for haml... | |
running install hook for haml | |
Successfully installed haml (2.0.9) | |
[~] $ integrity launch | |
/Users/imownbey/.rip/active/lib/haml/version.rb:11:in `read': No such file or directory - /Users/imownbey/.rip/active/VERSION (Errno::ENOENT) | |
from /Users/imownbey/.rip/active/lib/haml/version.rb:11:in `version' | |
from /Users/imownbey/.rip/active/lib/haml.rb:1004 |
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
ooga@placepop1 ~ $ sudo su -l ooga -c 'RAILS_ENV=production /usr/bin/rake -f /u/app/current/Rakefile --trace notifications:24hour' | |
(in /home/ooga) | |
** Invoke notifications:24hour (first_time) | |
** Invoke environment (first_time) | |
** Execute environment | |
** Execute notifications:24hour | |
rake aborted! | |
can't convert nil into String | |
/u/app/releases/20090707220916/vendor/rails/actionmailer/lib/action_mailer/vendor/tmail-1.2.3/tmail/mail.rb:551:in `quote' | |
/u/app/releases/20090707220916/vendor/rails/actionmailer/lib/action_mailer/vendor/tmail-1.2.3/tmail/mail.rb:551:in `read_multipart' |
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
diff --git a/public/stylesheets/styles.css b/public/stylesheets/styles.css | |
index 675dc8e..cef4fb0 100755 | |
--- a/public/stylesheets/styles.css | |
+++ b/public/stylesheets/styles.css | |
@@ -299,8 +299,8 @@ h3 { font-size: 18pt; } | |
float: right; | |
} | |
#place_top_1, #place_top_2, #place_top_3 { float: left; padding-bottom: 20px; } | |
-#place_top_1 { width: 58px; margin-right: 15px; } | |
-#place_top_2 { width: 277px; margin-right: 15px; font-size: 9pt; } |
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
/* GLOBAL */ | |
* { margin: 0; } | |
.clearboth { clear: both; } | |
a:link, a:visited { text-decoration: none; font-family: arial; color: #ff3300; } | |
img { border: 0; } | |
body { | |
font-family: arial; | |
font-size: 11pt; |
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
class StringHolder | |
def initialize(a_string) | |
@the_string = a_string | |
end | |
def get_that_string | |
puts @the_string | |
end | |
def self.stupid_method(a_string) |