Skip to content

Instantly share code, notes, and snippets.

View fijimunkii's full-sized avatar
🦁
𐂃͠

Harrison Powers fijimunkii

🦁
𐂃͠
View GitHub Profile
@chuckwagoncomputing
chuckwagoncomputing / xkcd_now_get.sh
Created February 27, 2014 01:40
get xkcd now image files
#!/bin/bash
for HOUR in {00..23}; do
for MINUTE in 00 15 30 45; do
wget "http://imgs.xkcd.com/comics/now/"$HOUR"h"$MINUTE"m.png"
done
done
exit
@JasonGhent
JasonGhent / index.js
Created December 11, 2014 15:46
HN Who Is Hiring Filter
/* Removes all non-toplevel comments and toplevel comments older than 24H */
var rows = document.querySelectorAll('table:nth-child(1) tr:nth-child(3) table:nth-child(4) > tbody > tr');
for (var i = 0; i < rows.length; i++) {
var row = rows[i];
var margin = row.querySelectorAll('img')[0];
var width = margin ? margin.getAttribute('width') : '';
width = width ? parseInt(width,10) : '';
if (width === 0) {
var head = row.querySelector('.comhead');
head = head.innerText;
@sukima
sukima / BetterCommitMessages.md
Last active August 29, 2015 14:15
My guidelines for writing better commit messages
#!/usr/bin/env bash
# This is an RVM Project .rvmrc file, used to automatically load the ruby
# development environment upon cd'ing into the directory
# First we specify our desired <ruby>[@<gemset>], the @gemset name is optional.
environment_id="ruby-1.9.3-p0@railsapp"
#
# Uncomment following line if you want options to be set only for given project.

If you're using GNU make and you need help debugging a makefile then there's a single line your should add. And it's so useful that you should add it to every makefile you create.

It's:

print-%: ; @echo $=$($) It allows you to quickly get the value of any makefile variable. For example, suppose you want to know the value of a variable called SOURCE_FILES. You'd just type:

make print-SOURCE_FILES If you are using GNU make 3.82 or above it's not even necessary to modify the makefile itself. Just do

ProjectM notes:
Install JackOSX 0.90 beta 13 from:
http://www.jackosx.com
Install cmake using Homebrew
Download Qt from:
https://qt-project.org/downloads
I used Qt4 and compiled it statically from source. Static building isn't necessary but made it (in some ways) easier to make a self-contained application.
Download ProjectM source code from:
https://sourceforge.net/projects/projectm/files/2.1.0/projectM-complete-2.1.0-Source.tar.gz/download
@mars
mars / gist:6086194
Last active December 20, 2015 06:29
DEPRECATED see comments: ember-testing: select an option (helper)
Ember.Test.registerHelper('selectFrom',
function(app, selector, value, description) {
// choose an option
find(selector).val(value);
// trigger the change
find(selector).change();
// assert the selected option
equal(find(selector+" option:selected").val(), value, description||"makes the selection");
// promise
return wait();
@ml242
ml242 / Git basics
Created November 8, 2013 23:08
Basic Git commands for groups from Jonathan's quick lecture
Git checkout -b "twilio_integration" (or feature in quotes that you're working on)
git checkout branch master (obviously moves back to master)
git push origin "twilio_integration" (or feature in quotes - just pushes the branch your working on)
when you're finished
git merge "twilio_integration" <- moves the twilio integration branch into the master branch
@ml242
ml242 / Amazon AWS demo from pbear
Last active December 28, 2015 05:39
Amazon AWS install
brew install imagemagick
gem install paperclip
-> add paperclip to gem file
gem install aws-sdk
gem 'paperclip'
gem 'aws-sdk'
rails new project
site :opscode
cookbook 'apt'
cookbook 'database'
cookbook 'set_locale', path: './cookbooks/set_locale'
cookbook 'postgresql_server_utf8', path: './cookbooks/postgresql_server_utf8'