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
| Strings and numbers are known as primitive data types. Primitive data types are basically the smallest building blocks for Ruby programs. In the next exercise, you'll work with more building blocks. | |
| Booleans are a primitive data type, just like Strings and Numbers. Booleans can have one of two values: true or false. | |
| There's one more primitive data type to explore before moving on: the Symbol. Symbols are like strings, only with less functionality. A Symbol is designated with a colon (:) to the left of a word. Symbols can contain any alpha-numeric character, but they must start with a letter. | |
| While "hello" + 3 doesn't make sense, you can mix strings and numbers if the return is meant to be a string. Combining strings and numbers is called string interpolation. String interpolation is the act of inserting a non-string value into a String, thus creating a new String. Interpolation is accomplished with the #{ } syntax. | |
| The modulo operator – % – returns the integer remainder of a quotient. For example, when d |
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
| [16] pry(#<Post>):1> self | |
| => #<Post:0x000000039e3d08 | |
| id: 1, | |
| title: "my new title", | |
| body: "my new body", | |
| created_at: Tue, 13 Oct 2015 21:49:28 UTC +00:00, | |
| updated_at: Wed, 14 Oct 2015 21:26:30 UTC +00:00> |
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
| $ heroku login | |
| $ heroku create | |
| $ git push heroku master | |
| WITH DESCRIPTION | |
| Deploying to Heroku | |
| It is time to deploy and share your app with the world. There are many choices for deploying and hosting Rails applications, and Bloc recommends the popular Heroku platform. Heroku makes it easy to manage and deploy Rails apps using the command line. |
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
| Before Each Checkpoint | |
| $ git status | |
| $ git checkout -b checkpoint-23-interfaces | |
| Switched to a new branch 'checkpoint-23-interfaces' | |
| After Each Checkpoint | |
| $ git status | |
| $ git add . | |
| $ git status | |
| $ git commit -m "Checkpoint 23 completed, interfaces" |
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 rs="rails s -p $PORT -b $IP" | |
| $ rs | |
| https://js-foundation-mbattur.c9users.io:8080/ | |
| jekyll serve --host $IP --port $PORT --baseurl '' |
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
| git remote -v |
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
| $ git push heroku master | |
| $ heroku run rake db:migrate |
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
| repl.it - an online, interactive Ruby shell. It is a full-feature terminal emulator that lets you experiment with and execute Ruby code. | |
| https://repl.it/languages/Ruby |
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
| The list of keyboard shortcuts can be found in the NetBeans Wiki. | |
| Turn On/Off Search Result highlights | |
| Alt + Shift + H | |
| Add/remove comment. Should work for all languages | |
| Ctrl + / or in mac ⌘ + / |
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
| cd blocipedia | |
| ls -la | |
| cd log | |
| ls -la | |
| tail test.log | |
| tail -f test.log | |
| Rails.logger.info |
OlderNewer