Skip to content

Instantly share code, notes, and snippets.

View kylehotchkiss's full-sized avatar
👨‍💻
Javascript

Kyle Hotchkiss kylehotchkiss

👨‍💻
Javascript
View GitHub Profile
@kylehotchkiss
kylehotchkiss / gruntfile-stuff.js
Created April 27, 2014 04:41
CDNify for Grunt/Wordpress - Failsafe code for conditionally using versioned CDN'd assets with wordpress, fails back to local files.
md5: {
compile: {
files: {
'<%= config.tmp %>/styles/': '<%= config.wordpress %>/**/*.css',
'<%= config.tmp %>/scripts/': '<%= config.wordpress %>/**/*.js'
},
options: {
keepBasename: true,
keepExtension: true,
after: function ( changes ) {

Keybase proof

I hereby claim:

  • I am kylehotchkiss on github.
  • I am kylehotchkiss (https://keybase.io/kylehotchkiss) on keybase.
  • I have a public key whose fingerprint is 0E64 19C9 F67E 7C4D 264D 4CC8 3DE4 9D15 999F F849

To claim this, I am signing this object:

@kylehotchkiss
kylehotchkiss / chase.js
Last active August 29, 2015 14:05
Get total of Chase rewards for next statement, because chase doens't tell you.
var transactions = [];
var i = 0;
jQuery(".summary a.expander").each(function( i ) {
transactions.push( this );
});
var getTransactions = (function getTransactions() {
if ( i < transactions.length ) {
@kylehotchkiss
kylehotchkiss / deleteCloudapp
Last active August 29, 2015 14:06
delete all cloudapp entries
var all = (function all() {
jQuery("[type=checkbox]:not(:checked)").click();
jQuery("[name=commit]").click();
setTimeout(function() { window.location = jQuery("#pagination").find("a").last().attr("href"); all() }, 1000);
})();
@kylehotchkiss
kylehotchkiss / monster.js
Created December 30, 2014 22:40
monster commit
//
// Description
// Show a Monster Commit image
//
module.exports = function( robot ) {
robot.hear(/monster commit/i, function( msg ) {
msg.reply( "http://files.kylehotchkiss.com.s3.amazonaws.com/monster-commit.jpg" );
});
};
var request = require("request");
var first = 10001;
var last = 99999;
var current = first;
var zips = {};
var convertZip = (function convertZip() {
if ( current < last ) {
@kylehotchkiss
kylehotchkiss / PlaceTaylor.json
Created February 24, 2015 01:49
Place Taylor
{"lyrics": [
"He said the way my blue eyes shined\nPut those Georgia stars to shame that night\nI said: That's a lie.\nJust a boy in a Chevy truck\nThat had a tendency of gettin' stuck\nOn backroads at night\nAnd I was right there beside him all summer long\nAnd then the time we woke up to find that summer gone",
"But when you think Tim McGraw\nI hope you think my favorite song\nThe one we dan=ced to all night long\nThe moon like a spotlight on the lake\nWhen you think happiness\nI hope you think that little black dress\nThink of my head on your chest\nAnd my old faded blue jeans\nWhen you think Tim McGraw\nI hope you think of me\n ",
"September saw a month of tears\nAnd thankin' God that you weren't here\nTo see me like that\nBut in a box beneath my bed\nIs a letter that you never read\nFrom three summers back\nIt's hard not to find it all a little bitter sweet\nAnd lookin' back on all of that, it's nice to believe\n ",
"When you think Tim McGraw\nI hope you think my favorite song\nThe one we
<?php
/**
*
* jQuery.whatchaDoin | iCal Proxy
* Copyright (c) 2010 Kyle Hotchkiss [Productions]
* ALL RIGHTS RESERVED
*
*/
if ( $_SERVER['HTTP_X_REQUESTED_WITH'] === 'XMLHttpRequest' ) {
function getOffset() {
/* Get the offset for moving the nav */
var width = $(document).width();
var margin = (width - 720) / 2;
var offset = $(".place.display").offset();
var position = $(".places").css("marginLeft");
position = parseInt(position.substring(0, position.indexOf("p")));
console.log(position);
@kylehotchkiss
kylehotchkiss / backup.py
Created August 15, 2011 06:07
Wordpress backup. Needs python, mysql, and bzip to work. Make it executable and place it in your cron for daily backups
#!/usr/bin/env python
##
## Backup for Wordpress
## By Hotchkissmade / Kyle Hotchkiss
##
import time, os
# ------------- #
# Configuration #