Skip to content

Instantly share code, notes, and snippets.

View cruffenach's full-sized avatar

Collin Ruffenach cruffenach

View GitHub Profile
We can make this file beautiful and searchable if this error is corrected: It looks like row 5 should actually have 20 columns, instead of 13. in line 4.
year,week,away_division_id,away_division_name,away_owners,away_team_abbrev,away_team_id,away_team_name,away_score,away_owner_name,home_division_id,home_division_name,home_owners,home_team_abbrev,home_team_id,home_team_name,home_score,home_owner_name,is_playoff,matchup_type
2012,1,0,Stark,{E4D517A5-003A-4BED-B0AD-C112CF953C58},WILS,1,The Revolution,145.1,Robb Wilson,0,Stark,{0FCB80AA-989F-4363-A860-69112E955D50},FML,8,My Bench is Blowing Up,137.12,FJ Pfitzer,false,NONE
2012,1,1,Baratheon,{7DCF1066-87D9-4987-BDD7-A9EA511E53DB},NICH,3,Showerin With Sandusky,100.02,Tanner Nicholson,1,Baratheon,{C417A672-B1F6-4098-AF88-4DC79D69C96D},KIDZ,6,Team Lines,95.52,Brian Lines,false,NONE
2012,1,2,Targaryen,{6D143E84-3D31-4ACC-98CD-4F72E1CD8B4E},RUFF,4,The Ron Fucking Swansons,101.86,Stephen Ruffenach,2,Targaryen,{C85A9FF9-8C7B-4A78-A078-D795B6B72A60},CRUF,12,Spike The Mic,92.54,Collin Ruffenach,false,NONE
2012,1,0,Stark,{D5E92792-3EC2-4B71-B7B8-5A862C2AF11C},RIDG,7,GriffinDor III,95.78,Adam Ridgeway,0,Stark,{0B73CD43-F23C
@cruffenach
cruffenach / gist:45a98ce6f2a49b5e859b
Last active June 30, 2018 13:23
Guilloche Drawing in Playgrounds
// Playground - noun: a place where people can play
import Cocoa
import QuartzCore
import XCPlayground
import Accelerate
func showMessage(message : String, messageIndex: Integer) {
let attributedString = NSAttributedString(string: message, attributes: NSDictionary(object: NSFont(name: "HelveticaNeue-Light", size: 24), forKey: NSFontAttributeName))
XCPCaptureValue("Message \(messageIndex)", attributedString)
@cruffenach
cruffenach / gist:7832838
Created December 6, 2013 22:01
Control Plex Up Key Appescript
set thePlayer to do shell script "defaults read ~/.plex/config.plist player_name"
set theURL to "mini.local:32400/system/players/" & thePlayer & "/navigation/moveUp"
do shell script "curl " & quoted form of theURL
set theURL to "mini.local:32400/system/players/" & thePlayer & "/playback/bigStepForward"
do shell script "curl " & quoted form of theURL

CWStatusBarNotification

CWStatusBarNotification is a library that allows you to easily create notifications that appear on the status bar.

demo

Requirements

CWStatusBarNotification uses ARC and requires iOS 7.0+.

@cruffenach
cruffenach / gist:6117012
Created July 30, 2013 21:12
Using Simple with my Fiancee
My Fiancee and I have both been using Simple exclusively for the last year. We both work and get regular paychecks. My account is the "primary" account. All of the bills, rent and most of our spending (going out etc.) along with savings happens in my account. Her account is for her spending, groceries, house stuff she sees when she is out and about etc.
To accomplish this my Fiancee has her paycheck direct deposited into 2 accounts. ~60% goes into mine where I immidiately put all of it into a Savings goal. The remaining 40% goes into hers where she spends some of it but is also growing a savings goal. 100% of my paycheck goes into my account. I have goals for all of our bills, along with a daily contributed to savings goal.
Overall we have had 0 problems making this situation work for us. Couples all have different ways of managing finances but we view ourselves as a single functional unit saving together. Having one person in the relationship designated as the primary account has been a very functional s
@cruffenach
cruffenach / gist:6117011
Created July 30, 2013 21:12
Using Simple with my Fiancee
My Fiancee and I have both been using Simple exclusively for the last year. We both work and get regular paychecks. My account is the "primary" account. All of the bills, rent and most of our spending (going out etc.) along with savings happens in my account. Her account is for her spending, groceries, house stuff she sees when she is out and about etc.
To accomplish this my Fiancee has her paycheck direct deposited into 2 accounts. ~60% goes into mine where I immidiately put all of it into a Savings goal. The remaining 40% goes into hers where she spends some of it but is also growing a savings goal. 100% of my paycheck goes into my account. I have goals for all of our bills, along with a daily contributed to savings goal.
Overall we have had 0 problems making this situation work for us. Couples all have different ways of managing finances but we view ourselves as a single functional unit saving together. Having one person in the relationship designated as the primary account has been a very functional s
- (UIImage *)imageScaledToSizeKeepingAspectRatioWithWidth:(CGFloat)targetMinimumWidth contextSize:(CGSize)contextSize {
CGSize originalSize = self.size;
CGFloat newHeight = (originalSize.height / originalSize.width) * targetMinimumWidth;
UIGraphicsBeginImageContextWithOptions(contextSize, NO, 1);
[self drawInRect:CGRectMake(0, 0, targetMinimumWidth, newHeight)];
UIImage *newImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return newImage;
body {
background-color:#d0e4fe;
}
h1 {
color:orange;
text-align:center;
}
p {
.highlight_blue {
color: #35A4D4;
}
.highlight_red {
color: #CC4555;
}
.highlight_green {
color: #58c472;
<pre>To <span style="color:green;">be</span> or <span style="color:red;">not</span> to be that is the question.<pre>