| ⌘T | go to file |
| ⌘⌃P | go to project |
| ⌘R | go to methods |
| ⌃G | go to line |
| ⌘KB | toggle side bar |
| ⌘⇧P | command prompt |
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
| * Documentation: https://help.ubuntu.com/ | |
| Welcome to your Vagrant-built virtual machine. | |
| Last login: Mon Jun 2 20:21:23 2014 from 10.0.2.2 | |
| vagrant [~]> touch hello.rb | |
| vagrant [~]> cd vagrant | |
| -bash: cd: vagrant: No such file or directory | |
| vagrant [~]> ls | |
| git-mania hello.rb index.html ls.txt post.html postinstall.sh tmp work | |
| vagrant [~]> ls | |
| git-mania hello.rb index.html ls.txt post.html postinstall.sh tmp work |
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
| def sign height, width, color = [] | |
| total = 0 | |
| sqrfeet = height * width | |
| total = sqrfeet * 15 | |
| print "Enter your colors seperated with commas: " | |
| color = gets.chomp.split(',').trim | |
| if color.length > 2 | |
| total += color.length * 15 | |
| else | |
| total += color.length * 10 |
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
| r = { | |
| "shrimp" => [ | |
| "algae", | |
| "other_shrimps", | |
| "seaweed", | |
| ], | |
| "toad" => [ | |
| "children", | |
| "flies", |
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
| #What is self? | |
| Self can be confusing because it refers to something different depending on the context. | |
| It refers to the object on which it is called (this could be a class or an instance of a class). | |
| In a class, it refers to the class itself, so if a class is called "Person", self is referring to "Person". | |
| In the context of a class, if you call a def (a new method) inside the class without an explicit receiver, it will create a new instance method. |
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
| r = { | |
| "shrimp" => [ | |
| "algae", | |
| "other_shrimps", | |
| "seaweed", | |
| ], | |
| "toad" => [ | |
| "children", | |
| "flies", |
- You want to run guard
- You want use Sublime plugins (like RSpec or Guard plugins)
Brew aka Homebrew is a package management system for Mac OSX.
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
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |