Skip to content

Instantly share code, notes, and snippets.

View charliegerard's full-sized avatar
💭
Making something 🧪

Charlie charliegerard

💭
Making something 🧪
View GitHub Profile

#Day 13

###Date In pry

require 'date' today = Date.today today.tuesday?

#Day 17

rails console is the same thing as pry.

Your terminal shoul have 4 tabs open with shell, server, pry and psql.

"rm -rf folder name" in pry to remove a folder

rake db:drop to remove a database

#Day19

###Steps to create Rails app

  • rails new
  • Update Gemfile and run bundle
  • update database yml
  • rake db:create
  • rails g migration create (table)
  • rails edit migration

#Day 21

##Branching

git branch shows the branches your repo already has git checkout -b login -> To go in the branch git branch

git checkout master goes back to main repo git checkout login --> goes back to branch