Skip to content

Instantly share code, notes, and snippets.

### Checks your account info.
git config --list
### Rename past Commits
1)git rebase --interactive HEAD~2
put reword in front of the commit you want to change name
2) another window again with the title of the commit you wrote reword in front
3) git push --force
<div class="modal fade" id="new_calendar">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button class="close" data-dismiss="modal">&times;</button>
</div>
<div class="modal-body">
<%= form_for [@room, Calendar.new] do |f| %>
<div class="row">
<div class="col-md-6">
# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
#
# This file is the source Rails uses to define your schema when running `rails
# db:schema:load`. When creating a new database, `rails db:schema:load` tends to
# be faster and is potentially less error prone than running all of your
# migrations from scratch. Old migrations may fail to apply correctly if those
# migrations use external dependencies or application code.
#
@cjlaborde
cjlaborde / postgres-cheatsheet.md
Created November 16, 2018 07:56 — forked from Kartones/postgres-cheatsheet.md
PostgreSQL command line cheatsheet

PSQL

Magic words:

psql -U postgres

Some interesting flags (to see all, use -h or --help depending on your psql version):

  • -E: will describe the underlaying queries of the \ commands (cool for learning!)
  • -l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)