Skip to content

Instantly share code, notes, and snippets.

View bassrock's full-sized avatar
:shipit:

Daniel Brooks bassrock

:shipit:
View GitHub Profile

Keybase proof

I hereby claim:

  • I am bassrock on github.
  • I am bass_rock (https://keybase.io/bass_rock) on keybase.
  • I have a public key ASBjgKL2R24XNZzTW7ySXl-eiu1ufXiykcSUKKGfjt1Lggo

To claim this, I am signing this object:

#!/bin/sh
### lolcommits hook (begin) ###
if [ ! -d "$GIT_DIR/rebase-merge" ]; then
export LANG="en_US.UTF-8"
export PATH="/usr/bin:/usr/local/bin:$PATH"
THE_MESSAGE="$(git log --pretty=format:'%h' -n 1) - $(git log -n 1 HEAD --format=format:%s%n%b)"
CURRENT="$(pwd)"
export LOLCOMMITS_DIR="$CURRENT/.company-lolcommits"
GIT_DIR_OLD=GIT_DIR
@bassrock
bassrock / AVIC.sh
Last active May 5, 2016 15:56
Recreates the Platform PRG for the NEX Decks from a zip.
#! /bin/sh
#requires http://www.paragon-software.com/home/extfs-mac/
AVICZIP=$1
mkdir -p work
unzip $AVICZIP -d work/
cd work/AVIC5000NEX/PLATFORM
dd if=PJ140PLT.PRG of=PJ140PLT.IMG bs=512 skip=1
dd if=PJ140PLT.PRG of=PJ140PLT.HEADER bs=512 count=1
MOUNTPOINT="$(hdiutil mount PJ140PLT.IMG)"
array=(`echo ${MOUNTPOINT}`)
@bassrock
bassrock / WKInterface Image
Created March 14, 2015 23:41
WKInterface Image
extension WKInterfaceObject {
var operationDictionary: NSMutableDictionary {
get {
var operations: NSMutableDictionary? = objc_getAssociatedObject(self, "operation") as NSMutableDictionary?
if(operations != nil) {
return operations!
}
operations = NSMutableDictionary()
objc_setAssociatedObject(self, "operation", operations, objc_AssociationPolicy(OBJC_ASSOCIATION_RETAIN_NONATOMIC))
@bassrock
bassrock / BuildForm
Created June 19, 2014 16:39
DateRangeFilter For Form Filter Bundle
$builder->add('createdAt','filter_time_period', array(
'left_date_options' => array(
'label' => 'Start Date:',
'attr' => array(
'class' => 'form-control input-sm',
),
'empty_value' => array('year' => 'Year', 'month' => 'Month', 'day' => 'Day')
),
'right_date_options' => array(
'label' => 'End Date:',
@bassrock
bassrock / JSQMessagesViewController.podspec
Created April 25, 2014 05:48
A Podspec for the 5.0 branch of JSQMessagesViewController
Pod::Spec.new do |s|
s.name = 'JSQMessagesViewController'
s.version = 5.0
s.summary = 'A messages UI for iPhone and iPad.'
s.homepage = 'https://github.com/jessesquires/MessagesTableViewController'
s.social_media_url = 'https://twitter.com/jesse_squires'
s.license = 'MIT'
s.authors = { 'Jesse Squires' => 'jesse.squires.developer@gmail.com' }
s.source = { :git => 'https://github.com/jessesquires/MessagesTableViewController.git', :branch => 'version_5_release' }
s.platform = :ios, '7.0'
@bassrock
bassrock / NSObject+AssociatedObjects.h
Created July 29, 2012 07:26 — forked from ecentinela/NSObject+AssociatedObjects.h
Blocks support for RestKit RKClient
#import <Foundation/Foundation.h>
@interface NSObject (AMAssociatedObjects)
- (void)associateValue:(id)value withKey:(void *)key; // Retains value.
- (id)associatedValueForKey:(void *)key;
@end