Skip to content

Instantly share code, notes, and snippets.

View seabre's full-sized avatar

Sean Brewer seabre

  • CrowdFiber
  • Chattanooga, TN
View GitHub Profile
@seabre
seabre / transfer_local_to_remote_mysql.sh
Created July 26, 2013 19:51
Transfer local MySQL db to remote host
mysqldump -u localuname -plocalpwd localdbname | mysql -u remoteuname -premotepwd --host=remotehost -C remotedbname
require 'mandrill'
m = Mandrill::API.new
message = {
:subject => "Hello from the Mandrill API",
:from_name => "Your name",
<script>
Modernizr.load({
test: Modernizr.mq('only all'),
nope: 'path_to_respond.js'
});
</script>
@seabre
seabre / core.clj
Last active December 16, 2015 11:19 — forked from anonymous/core.clj
(ns clj-sauce.core
(:require
[clj-webdriver.remote.server :as rs]
[clj-webdriver.taxi :as taxi]
[clj-webdriver.firefox :as ff]))
(defn init-grid
"Initializes the grid code"
[port cred spec]
@seabre
seabre / app.js
Created April 6, 2013 03:56
Basic WebGL (with three.js) Template
var App = App || {};
// helper to create proper asset paths if an asset host is configured
App.assets = {
assets : {
<% AssetsUtil.images.each do |img| %>
"<%= img %>" : "<%= asset_path(img) %>",
<% end %>
},
@seabre
seabre / git_cookbook.md
Last active December 14, 2015 17:29
Git cookbook.

Git Cookbook

Checkout remote branch

git checkout -t origin/my_remote_branch

Change current directory to root of git project

@seabre
seabre / constant.clj
Last active December 14, 2015 08:59
Used in live-coding session for: https://soundcloud.com/seabre/constant
(use 'overtone.live)
(use 'overtone.inst.sampled-piano)
; arpeggiate-chord:
;
; Arpeggiate a given chord.
;
; instrument - Some sort of instrument function.
; a-chord - List of midi nums.
; spacing - Spacing between notes in milliseconds.
(function(){var a=document.createElement("script");a.src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.js";a.type="text/javascript";document.getElementsByTagName("head")[0].appendChild(a);})()
@seabre
seabre / minblues.clj
Created February 26, 2013 06:11
Just playing around with stuff from the Overtone wiki. An endless minor blues.
; Just playing around with stuff from the overtone wiki.
; An endless minor blues.
(use 'overtone.live)
(use 'overtone.inst.sampled-piano)
(defn play-chord [a-chord]
(doseq [note a-chord] (sampled-piano note)))