Skip to content

Instantly share code, notes, and snippets.

View jimmyeisenhauer's full-sized avatar

Jimmy Eisenhauer jimmyeisenhauer

View GitHub Profile
@jimmyeisenhauer
jimmyeisenhauer / learninruby1
Created August 26, 2011 00:20
code sample for my blog article...and a test of github:gist fetaure
rails new learninruby
cd learninruby
bundle install
rails server //It worked on the dev server!
git add .
git commit -m "first commit"
heroku create jameseisenhauer
this is a test of gist command
@jimmyeisenhauer
jimmyeisenhauer / gist:2795771
Created May 27, 2012 00:58
Drop and Rebuild Heroku database
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
@jimmyeisenhauer
jimmyeisenhauer / build.sh
Created November 30, 2012 18:58 — forked from jonah-williams/build.sh
Command line iOS project builds and over-the-air distribution
#!/bin/bash
# https://gist.github.com/949831
# http://blog.carbonfive.com/2011/05/04/automated-ad-hoc-builds-using-xcode-4/
# command line OTA distribution references and examples
# http://nachbaur.com/blog/how-to-automate-your-iphone-app-builds-with-hudson
# http://nachbaur.com/blog/building-ios-apps-for-over-the-air-adhoc-distribution
# http://blog.octo.com/en/automating-over-the-air-deployment-for-iphone/
# http://www.neat.io/posts/2010/10/27/automated-ota-ios-app-distribution.html
def create_button
@driver.find_element(:link, 'Create')
end
def create_button_click
@wait = Selenium::WebDriver::Wait.new(timeout: 8)
puts 'DEBUG: Clicking Create Button'
create_button.click
puts 'DEBUG: Waiting for View This Challenge'
@wait.until { @driver.find_element(:link, 'view this challenge') }
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jimmyeisenhauer
jimmyeisenhauer / nightwatch_chai.js
Created August 12, 2015 21:36
Recreate nightwatch.js chai issue
var expect = require('chai').expect;
module.exports = {
before : function(browser) {
console.log('Setting up...');
},
@jimmyeisenhauer
jimmyeisenhauer / cycleOSXWifi
Created March 14, 2016 05:44
Shell script to cycle osx wifi connection in a loop
#!/bin/bash
COUNTER=0
while [ $COUNTER -lt 10 ]; do
echo The counter is $COUNTER
let COUNTER=COUNTER+1·
networksetup -setairportpower airport off; networksetup -setairportpower airport on
sleep 5
done
var Benchmark = require('benchmark');
var escapeRegex = require('escape-string-regexp');
var suite = new Benchmark.Suite;
var text = "Contrary to popular belief, Lorem Ipsum is not simply random text. mouse It has roots in a mouse piece of classical Latin \
literature from 45 BC, making it over 2000 mouse years old. Richard McClintock, a Latin professor at Hampden-Sydney College in Virginia, \
looked up one of the more obscure Latin words, consectetur, from a Lorem Ipsum mouse passage, and going through the cites of the word in \
classical literature, fish discovered the mouse undoubtable source. Lorem mouse Ipsum comes from sections 1.10.32 and 1.10.33 of de Finibus \