Skip to content

Instantly share code, notes, and snippets.

View bloopletech's full-sized avatar

Brenton 'B-Train' Fletcher bloopletech

View GitHub Profile
package main
import (
"fmt"
//"os"
//"regexp"
"strings"
"encoding/json"
"github.com/SlyMarbo/rss"
"github.com/moovweb/gokogiri"
<script type="text/javascript">
$(function() {
$("#expand-copyrights").click(function(event) {
alert('ooo');
event.preventDefault();
alert('ooo');
$("#extended-copyrights").show();
});
});
</script>
Xft.dpi: 96
Xft.antialias: true
Xft.rgba: rgb
Xft.hinting: true
Xft.hintstyle: hintslight
Xft.lcdfilter: lcddefault
XTerm*utf8: 2
! to match gnome-terminal "Linux console" scheme
@bloopletech
bloopletech / .i3_apple
Created February 7, 2013 08:41
i3 setup
#!/bin/bash
i3-msg 'workspace 2; rename workspace 2 to Apple;'
i3-msg 'workspace Apple; exec chrome --new-window;'
i3-msg 'workspace Apple; exec ~/.i3/xterm_in_directory ~/work/apple;'
def store_dir
"uploads/" + case model.class
when Gallery
model.gallery.page.site.id
when Content
model.content.page.site.id
when MenuCategory
model.menu_category.menu.page.site.id
else
model.site.id
set nocompatible
set backspace=indent,eol,start
set ignorecase
set t_Co=256
colorscheme murphy
set guioptions-=T
set expandtab
set autoindent
set shiftwidth=2
SHELL=/bin/bash
# m h dom mon dow command
0 0 * * * /.../run_in_current rake db:backup
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "bigint.h"
/* this library provides for a bigint type, which can hold numbers of an unlimited length.
You can add them together as well.*/
class ActiveRecord::Base
def self.fake_model(*columns_arr)
alias_method :save, :valid?
def columns
@columns ||= []
end
@columns ||= []
#!/usr/bin/ruby
=begin
Depends on recent mplayer with libfaac and libx264 installed before compiling/installing mplayer.
Also, to read AAC audio, libfaad, and to read MP3 audio, libmp3lame, must be installed before compiling/installing mplayer.
If these requirements are not met, don't even try to run this script.
Mencoder may warn about "REMEMBER: MEncoder's libavformat muxing is presently broken"; this is irrelevant for encoding videos in H.264 for the iPod Touch/iPhone,
as they don't use B-frames.
Usage: