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
# # Make gems available | |
# require 'rubygems' | |
# | |
# # http://drnicutilities.rubyforge.org/map_by_method/ | |
# begin | |
# require 'map_by_method' | |
# rescue LoadError | |
# puts "map_by_method is not installed. To enable, run: gem install map_by_method" | |
# 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
ruby-1.8.7-p302: | |
system: | |
uname: "Darwin linus-oleanders-macbook.local 10.6.0 Darwin Kernel Version 10.6.0: Wed Nov 10 18:13:17 PST 2010; root:xnu-1504.9.26~3/RELEASE_I386 i386" | |
zsh: "zsh 4.3.9 (i386-apple-darwin10.0)" | |
bash: "GNU bash, version 3.2.48(1)-release (x86_64-apple-darwin10.0)" | |
rvm: | |
version: "rvm 0.1.47 by Wayne E. Seguin ([email protected]) [http://rvm.beginrescueend.com/]" |
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
LoadError: no such file to load -- movie_searcher | |
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:29:in `gem_original_require' | |
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:29:in `require' | |
from (irb):3 |
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
- (id)initWithCoder:(NSCoder *)coder | |
{ | |
if(self=[super initWithCoder:coder]){ | |
//register for all the image types we can display | |
[self registerForDraggedTypes:[NSImage imagePasteboardTypes]]; | |
} | |
return self; | |
} |
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 SomeController < NSView | |
def initWithFrame(frame) | |
super(frame) | |
return self | |
end | |
def awakeFromNib | |
self.registerForDraggedTypes [NSStringPboardType, nil] | |
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
# This returns just one movie | |
Movie.joins(:images => [:size, :type]).includes(:genres, :images).where(:images => {:sizes => {:name => 'thumb'}, :types => {:name => 'poster'}}).select('DISTINCT images.url').limit(5) | |
# This returns all 5 movies, but every movie have a lot of images | |
Movie.joins(:images => [:size, :type]).includes(:genres, :images).where(:images => {:sizes => {:name => 'thumb'}, :types => {:name => 'poster'}}).limit(5) |
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
-- Example of a four bit adder | |
library ieee; | |
use ieee.std_logic_1164.all; | |
-- definition of a full adder | |
entity FULLADDER is | |
port (a, b, c: in std_logic; | |
sum, carry: out std_logic); | |
end FULLADDER; | |
architecture fulladder_behav of FULLADDER is | |
begin |
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
alias gp='git push origin master' | |
alias gs='git status' | |
alias gc='git checkout' | |
alias gcp='git cherry-pick' | |
alias gd='git diff --stat' | |
alias gpo='git push origin' | |
alias gb='git branch' | |
# Laddar om alla inställningar | |
alias s='source ~/.bash_profile' |
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
source :gemcutter | |
gem 'rails', '3.0.3' | |
# Layout | |
gem 'haml', '~> 3.0.18' | |
gem "compass", "~> 0.10.5" | |
group :production do |
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
/Applications/TextMate.app/Contents/SharedSupport/Support/lib/osx/plist.bundle: dlopen(/Applications/TextMate.app/Contents/SharedSupport/Support/lib/osx/plist.bundle, 9): no suitable image found. Did find: (LoadError) | |
/Applications/TextMate.app/Contents/SharedSupport/Support/lib/osx/plist.bundle: no matching architecture in universal wrapper - /Applications/TextMate.app/Contents/SharedSupport/Support/lib/osx/plist.bundle | |
from /Applications/TextMate.app/Contents/SharedSupport/Support/lib/ui.rb:3 | |
from /Applications/TextMate.app/Contents/SharedSupport/Bundles/Ruby.tmbundle/Support/RubyMate/stdin_dialog.rb:1:in `require' | |
from /Applications/TextMate.app/Contents/SharedSupport/Bundles/Ruby.tmbundle/Support/RubyMate/stdin_dialog.rb:1 |