This file contains 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 XlsExport | |
attr_accessor :interview | |
def get_xls | |
user_interviews = interview.user_interviews.all_finished.includes(:user).includes(:interview_ratings) | |
users = User.find_all_by_id(user_interviews.map {|user_interview| user_interview.interview_ratings.includes(:criterion_ratings).map{|interview_rating| interview_rating.user_id if interview_rating.criterion_ratings.where("criterion_ratings.value IS NOT NULL").count > 0 }}.flatten.uniq) | |
all_criterion_ratings = {} | |
user_interviews.each do |user_interview| | |
user_ratings = {} | |
user_interview.interview_ratings.each do |interview_rating| |
This file contains 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 XlsExport | |
attr_accessor :interview | |
def get_xls | |
user_interviews = interview.user_interviews.all_finished.includes(:user).includes(:interview_ratings) | |
users = User.find_all_by_id(user_interviews.map {|user_interview| user_interview.interview_ratings.includes(:criterion_ratings).map{|interview_rating| interview_rating.user_id if interview_rating.criterion_ratings.where("criterion_ratings.value IS NOT NULL").count > 0 }}.flatten.uniq) | |
all_criterion_ratings = {} | |
user_interviews.each do |user_interview| | |
user_ratings = {} | |
user_interview.interview_ratings.each do |interview_rating| |
This file contains 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
Settings -- User | |
Located in "Sublime Text 2" --> Preferences --> Settings --> User | |
{ | |
"color_scheme": "Packages/User/Monokai Soda.tmTheme", | |
"font_face": "Meslo LG S DZ", | |
"font_size": 16.0, | |
"rulers": | |
[ |
This file contains 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
#note: there is more to this than is listed here.. this is just minimal stuff, if you want to get even more high speed, contact me. | |
#OS X Named Streams Issue for OSX 10.6 | |
echo "[default]" | sudo tee /etc/nsmb.conf | |
echo "streams=no" | sudo tee -a /etc/nsmb.conf | |
Install Homebrew | |
sudo mkdir /usr/local |
This file contains 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
source "$HOME/.hashrc" | |
# Store 10,000 history entries | |
export HISTSIZE=10000 | |
# Don't store duplicates | |
export HISTCONTROL=erasedups | |
# Append to history file | |
shopt -s histappend | |
VISUAL=vim |
This file contains 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 Animal | |
def breathe | |
# code to take a breath. | |
end | |
end | |
Module Nutrition | |
This file contains 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 Person | |
attr_accessor :name, :email, :age | |
def initialize(n, e, a=18) | |
@name = n | |
@email = e | |
@age = a | |
end | |
def to_s |
This file contains 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 Person | |
attr_accessor :name, :gender, :pets | |
def initialize(n, g) | |
@name = n | |
@gender = g | |
@pets = [] | |
end | |
def to_s | |
"#{name} is a #{gender} and has #{pets.count} pets." | |
end |
This file contains 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 Person | |
attr_accessor :name, :gender, :pets | |
def initialize(n, g) | |
@name = n | |
@gender = g | |
@pets = {} | |
end | |
def to_s | |
"#{name} is a #{gender} and has #{pets.count} pets : #{pets}." | |
end |
This file contains 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
Show hidden characters
{ | |
"color_scheme": "Packages/User/Monokai Soda.tmTheme", | |
"font_face": "Source Code Pro", | |
"font_size": 21.0, | |
"rulers": | |
[ | |
80 | |
], | |
"tab_size": 2, | |
"theme": "Soda Dark.sublime-theme", |