Skip to content

Instantly share code, notes, and snippets.

View quicksnap's full-sized avatar
🎮
GitHub has statuses?!

Dan Schuman quicksnap

🎮
GitHub has statuses?!
View GitHub Profile
# Author: https://gist.github.com/1237902
#
# run with: god -c /path/to/config.god [add -D if you want to not-deamonize god]
# This is the actual config file used to keep the delayed_job running
APPLICATION_ROOT = "/home/mildavw/ddmaps"
RAILS_ENV = "production"
God.watch do |w|
w.name = "delayed_job_production"
@quicksnap
quicksnap / 0_some_file
Last active December 12, 2015 05:08
`cat` and `grep`
Hey I'm some file.
Bob
Bob Joe Barny
Hey Unix
hey Linux
<script>
function runProgram(){
var userResponse_base = document.getElementById('txtBox').value;
var userResponse = encodeURI(userResponse_base);
window.top.location = "https://drive.google.com/a/boysandgirlsaid.org/?tab=co#search/" + userResponse;
}
Process: Google Chrome [288]
Path: /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
Identifier: com.google.Chrome
Version: 25.0.1364.84 (1364.84)
Code Type: X86 (Native)
Parent Process: launchd [274]
User ID: 502
Date/Time: 2013-02-20 10:46:10.413 -0800
OS Version: Mac OS X 10.8.2 (12C60)
$ cat ~/.aliases
newalias() {
echo "\n" >> ~/.aliases
echo "alias $1=\"$2\"" >> ~/.aliases
. ~/.aliases
}
git push production && ssh [email protected] "cd production && git pull origin && ./clearCache.php"
@quicksnap
quicksnap / brickr.coffee
Created April 21, 2013 22:39
So awesome
(($) ->
$.fn.brickr = (options) ->
# $firstEl = $( @[0] )
# Return chainability
$.each @, (i, el) ->
# Optional: things to each ele
undefined
)(jQuery)
(($) ->
describe 'Brickr', ->
opts = api_key: 'foo-bar-baz-123'
it 'should instantiate', ->
$( ).brickr.should.be.a( 'function' )
it 'should chain properly', ->
$obj = $( 'div' ).brickr( )
var MODULE = (function (my) {
var _private = my._private = my._private || {},
_seal = my._seal = my._seal || function () {
delete my._private;
delete my._seal;
delete my._unseal;
},
_unseal = my._unseal = my._unseal || function () {
my._private = _private;
my._seal = _seal;
#include <iostream>
#include <string>
using namespace std;
int main() {
bool test1 = 1;
bool test2 = 0;
bool test3 = 123;
bool test4 = -4;
bool test5 = "HEY";