Skip to content

Instantly share code, notes, and snippets.

View SKGrimes's full-sized avatar

S.K. Grimes SKGrimes

View GitHub Profile
@SKGrimes
SKGrimes / keybase.md
Last active February 11, 2016 15:55
keybase.md

Keybase proof

I hereby claim:

  • I am skgrimes on github.
  • I am skg (https://keybase.io/skg) on keybase.
  • I have a public key ASCLTzrHuwZhfldxBzDhV1qwqFRzCqiRQ_aib2cAIYbLXwo

To claim this, I am signing this object:

heroku pg:reset SHARED_DATABASE --confirm fasterfaster
heroku run rake db:migrate
heroku run console
Rails.cache.clear
heroku restart
- manually add one record to test
- run performance test
#!/bin/sh
#This is a simple bash script that will poll github for changes to your repo,
#if found pull them down, and then rebuild and restart a Jekyll site running
#in Nginx. Note, we cannot use cron to schedule a job every 5 seconds, so we create
#a script that executes an infinite loop that sleeps every 5 seconds
#We run the script with nohup so it executes as a background process: $nohup ./update-jekyll
while true
do
Step 1: Right click the "My Computer" icon on your desktop,
or start up menu and click the properties tab.
Step 2: Click the advanced tab and then click the Environment
Variables tab (should be at the bottom of the advanced page)
Step 3: Under system variables click "New" Add the variable
name: "SUBLIME" and value of "C:\Program Files\Sublime Text 2\"
(please note this could vary depending on your install location)
Then click "Okay"

####Angular Testing Part-1

####Why do we test code...in an automated fashion.

Mark Ethan Trostler ( Google )..from Testable Javascript :

You have to write unit tests, so quit messing around and write some.

From the angular docs ( Many people at Google ):

JavaScript is a dynamically typed language which comes with great power of expression, but it also comes with almost no help from the compiler. For this reason we feel very strongly that any code written in JavaScript needs to come with a strong set of tests. We have built many features into Angular which makes testing your Angular applications easy. So there is no excuse for not testing.

####What is a hash?

A semi-famous joke in computer science goes like this:

There are only two hard things is computer science: naming things, cache invalidation, and off by one errors.

In terms of the first diffuculty, naming things, let's think about Hash. What does that bring to mind....breakfast potatoes?..something rockstars in the 1960's smoked in Morrocco?...Twitter hash tags?

Hash is actually short for HashMap...still not very descriptive, Lets see if we can do a bit better.