Skip to content

Instantly share code, notes, and snippets.

View iceydee's full-sized avatar

Mio Nilsson iceydee

View GitHub Profile
@iceydee
iceydee / keybase.md
Created January 18, 2021 06:07
Keybase Verification

Keybase proof

I hereby claim:

  • I am iceydee on github.
  • I am plingot (https://keybase.io/plingot) on keybase.
  • I have a public key ASDni1-Rm70q9GOyswaniSw9vLsWcSNtIHxbvt-Kfixkcgo

To claim this, I am signing this object:

#import "KWHCMatcher.h"
#import "KWMessageTracker.h"
#import "Kiwi.h"
@interface NSNotificationMatcher : NSObject <HCMatcher>
{
NSDictionary *_userInfo;
}
+ (id)matcherWithUserInfo:(NSDictionary *)dictionary;
@iceydee
iceydee / convert_cookies_plist.rb
Created October 5, 2011 06:33
A simple script to convert Safari Cookies.plist to cookies.txt format. This is a minor rewrite from the script found here: http://seriousorange.com/2010/01/converting-safari-cookies-plist-to-cookies-txt/
#!/usr/bin/env ruby
require 'plist'
result = Plist::parse_xml(File.expand_path("~/Library/Cookies/Cookies.plist"))
result.each do |r|
arr = []
arr += [r["Domain"], "TRUE"]
arr += [r["Path"], "FALSE"]
arr << r["Expires"].strftime("%s")
@iceydee
iceydee / Align Colors.jsx
Created September 10, 2011 21:43
A simple Illustrator CS5 script to 4-bit align all of the swatches. (Useful for working with RGBA4444 images). Can easily be modified to work with other types of color formats (see the alignment part of alignedColor function).
var docRef = app.activeDocument;
app.activeDocument.RGB
var alignedColor = function(color, alignment) {
if (typeof(alignment) == "undefined") {
alignment = 16;
}
var returnColor = (Math.round((color + 1) / alignment) * alignment) - 1;