Skip to content

Instantly share code, notes, and snippets.

View JaredRoth's full-sized avatar

Jared Roth JaredRoth

View GitHub Profile
@JaredRoth
JaredRoth / personal_pitch.md
Last active June 6, 2016 18:07
Personal Project Pitch

Event Management Contractor

Pitch

Simple web-app for managing user and event applications geared towards users and admins of low technical ability.

Problem

Very small businesses and their business owners without technical experience waste an inordinate amount of time and effort by failing to embrace modern business technologies. They frequently resort to juggling multiple spreadsheets and using physical mail for mass mailers adding countless hours to easily automated processes. Additionally, their lack of security understanding leaves them open to attack and liable for bankrupting lawsuits.

Concerns:

  • Should the parent company have understood the team dynamic before acquisistion/project assignment?
  • Does this signify an inadvertant rebranding of our company (skewed towards "older" projects)?
  • Are our developers simply being childish and unprofessional?

Suggestions:

  • Acquire more information (user stories, etc)
  • Allow team members to move on to projects that they actually enjoy and acquire those that will do the job
  • Highlight the opportunities for growth (simplified UX, etc)
  • Highlight similarites to previous work
  • What does it mean to concatenate files? Find an image of an example concatenated file. Why would we want to concatenate files?
  • Collect the contents of multiple files into one file. - So that the browser has to make fewer requests.
  • What does it mean to precompile files? What does this have to do with coffeescript and sass files?
  • I believe it is the process of taking a secondary language and compiling it into a web standard language. CoffeScript and Sass are languages that comile into JS and CSS.
  • What does it mean to minify files? Find an image of an example minified file. Why would we want to minify files?
  • It removes whitespace and other file-size "fluff" - We do this to reduce load times.
  • Start up the server for Catch 'em All (rails s) and navigate to http://localhost:3000/assets/application.js. Then open up the code for application.js in your text editor. Why are these not the same?
  • The file we see online is a concatenated file of all the javascript in the project
  • What is a manifest (in
  • git stash
    • Records the current state of your directory without committing. Restores directory to match HEAD.
  • git stash apply
    • Restores the previous stash. Will overwrite commits.
  • git shortlog
    • Groups git log by author and displays only the commit headers (not the messages or any other log info).
  • git commit --amend
    • Replaces the last commit with this one, adding to the message. (Do not do this if the commit has already been published)
  • git reset --hard
  • Discards all changes since the last commit

Models, Databases, Relationships in Rails

What is the difference between a primary key and a foreign key? Where would we find a primary key? What would it be called by default? Where would we find a foreign key? What is the naming convention for a foreign key?

  • Primary key determines uniqueness of an entry in a table (generally, but not necessarily "id")
  • Foreign key references an entry in another table (by its primary key) ("foreignTableName_id")

Write down one example of:

  • Spouses/Couples, Person-SSN,
  • House-Occupants, School-Students
  • Albums-Artists, Students-Classes, Video Games-Players
@JaredRoth
JaredRoth / cfu_crud_in_sinatra.markdown
Last active March 23, 2016 04:08 — forked from rwarbelow/cfu_crud_in_sinatra.markdown
CRUD in Sinatra -- Check for Understanding
  1. Define CRUD.
  • The acronym for the basic actions carried out in web applications: Create, Read, Update, Delete
  1. There are seven verb + path combinations that are necessary in a basic Sinatra app in order to provide full CRUD functionality. List each of the seven combinations, and explain what each is for.
  • Read / GET - Displaying the collection
  • Read / GET - Displaying an item
  • Create / GET - Displaying the form for creating an item
  • Create / POST - Submitting the info from that form for creation
  • Update / GET - Displaying the form for changing an item
  • Update / PUT - Submitting the info from that form for changing
  • Delete / DELETE - Removing a designated item
@JaredRoth
JaredRoth / Mod1_tools.md
Last active March 26, 2016 00:28
Make Mod 1 a little easier: Using Atom, Terminal, and other tools

Jared

iTerm

  • Get it
  • Preference changes to get certain shortcuts to behave the same as the rest of the system:
  • Preferences -> profiles -> Keys
  • ⌘-left: Send Hex Codes: 0x01
  • ⌘-right: Send Hex Codes: 0x05
  • Left option key: +Esc
  • Option-left: Send Escape sequence: b
  • Option-right: Send Escape sequence: f
@JaredRoth
JaredRoth / Outline.md
Last active March 22, 2016 20:18
Make Mod 1 a little easier: Using Atom, Terminal, and other tools

Jared

iTerm

Bash Profile

  • To access it: atom ~/.bash_profile
  • Useful aliases and functions:
  • alias ..='cd ..'
  • alias ga='git add'

Introduction to Sinatra

1. What is the purpose of the server file (routing)?

  • The server file specifies all routing requests and related operations.

2. How do you pass variables into the views?

  • As instance variables or using the locals hash

3. How can we interpolate ruby into a view (html)?