Skip to content

Instantly share code, notes, and snippets.

Joshua Montross jmontross

Block or report user

Report or block jmontross

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@jmontross
jmontross / gist:5717616
Created Jun 5, 2013
american express add up the payments from transaction detail view page.
View gist:5717616
var amountSpent = 0;
$('.colAmmount').each(function($this,foo) { amountSpent += parseInt(foo.innerHTML.replace(/ /g,'').replace(/\n/g,'')) })
console.log(amountSpent);
$('.colAmmount').each(function($this,foo){ console.log($this,parseInt(foo.innerHTML.replace(/ /g,'').replace(/\n/g,''))) })
@jmontross
jmontross / index.html
Created May 28, 2013
A CodePen by Joshua Montross.
View index.html
<div class="bigcircle">
<div class="circle circle1"> 1 </div>
<div class="circle circle2"> 2 </div>
<div class="circle circle3"> 3 </div>
<div class="circle circle4">4 </div>
@jmontross
jmontross / gist:5647271
Created May 24, 2013
how to get more than 1000 s3 assets using fog gem in ruby
View gist:5647271
storage = Fog::Storage.new({:provider => 'AWS', :aws_access_key_id => ACCESS_KEY_ID, :aws_secret_access_key => SECRET_ACCESS_KEY})
files = storage.get_bucket("lessonOverFlow",{'max-keys' =>'100000'})
truncated = files.body['IsTruncated']
the_response = files.body['Contents']
while truncated
files = storage.get_bucket("lessonOverFlow",{'max-keys' =>'100000', 'marker' => files.body['Contents'].last["Key"]})
truncated = files.body['IsTruncated']
the_response = the_response + files.body['Contents']
end
View gist:5513448
var FizzBuzz = function(x)
{
function isInt(n) {
return n % 1 === 0;
}
function divThree(n) {
var nThree = n / 3;
return nThree;
}
function divFive(n) {
@jmontross
jmontross / javascript closure example
Created Mar 19, 2013
javascript closure example
View javascript closure example
var addMultipleGameKeysModule = (function () {
var iGameKey;
function getGameKeys() {
var gameKeyList = [];
$j("input'[name*='GAMEKEY']").each(function(i){
gameKeyList.push($j(this).val());
});
return gameKeyList;
View gist:5068637
// var arduino = require("johnny-five")
// , board = new arduino.Board();
// /*, photo = require('./photo')
// , sendgrid = require)''
// */
// board.on("ready", function(){
// var button = new arduino.Button(7);
@jmontross
jmontross / set_up_my_machine.sh
Last active Dec 14, 2015
Run this file from ~/cookbooks/setup_my_machine.sh with bash after doing the following steps 1. installing command line tools for osx (download x-code from app store, open x-code, preferences -> downloads > command line tools) 2. mkdir ~/cookbooks; cd ~/cookbooks; git clone https://github.com/opscode-cookbooks/dmg; git clone git://github.com/jmo…
View set_up_my_machine.sh
#!/bin/bash
# This shell script was created at solowizard.com
#
# Usage:
# Running the script remotely:
# bash < <(curl -s http://www.solowizard.com/soloist_scripts/frsp9k.sh )
# Running the script if you have downloaded it:
# ./frsp9k.sh
#
# http://github.com/tommyh/solo_wizard
@jmontross
jmontross / TODO-Pointmanj
Created Aug 23, 2012
pointmanj improvements
View TODO-Pointmanj
consider using xml format of standard resume.
@jmontross
jmontross / launch_sublime_from_terminal.markdown
Created Aug 9, 2012 — forked from artero/launch_sublime_from_terminal.markdown
Launch Sublime Text 2 from the Mac OS X Terminal. slim is the new mate
View launch_sublime_from_terminal.markdown

I forked this from someon symlinking subl to sublime.

I want slim, because it's well, slimmer.

This assumes you installed sublime text 2. if not - do that here - http://www.sublimetext.com/2

Sublime Text 2 ships with a CLI called subl (why not "sublime", go figure). This utility is hidden in the following folder (assuming you installed Sublime in /Applications like normal folk. If this following line opens Sublime Text for you, then bingo, you're ready.

The reason why sublime is not shipped default is that it is too long to type. the reason for subl being lame is that it's not a word. textmate is great because I type mate to get along editing whatever directory or file I want. slim is the new mate and gives me those good feelings the way it is typed with few finger movements and has meaning.

ln -s /Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl /usr/local/bin/slim

@jmontross
jmontross / Agile
Created Aug 6, 2012
Agile Thoughts
View Agile
treat the business as an experiment - the business decisions are assumptions ...
discover how people learn and interact with a course - not how they should learn and interact.
conduct experiments to determine what techniques will work in their unique circumstances.
You can’t perform that action at this time.