Skip to content

Instantly share code, notes, and snippets.

🐫
🥶

Steve Moser stevemoser

🐫
🥶
Block or report user

Report or block stevemoser

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@stevemoser
stevemoser / IncompatibleAppsList.plist
Created Jun 20, 2019
List of 235 apps incompatible with macOS Catalina 10.15
View IncompatibleAppsList.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IncompatiblePaths</key>
<array>
<dict>
<key>Application Name</key>
<string>Sxs Memory Card Driver</string>
<key>Blurb</key>
View products.json
{
"products": [
{
"name": "macbook-12-inch",
"brand": "MacBook",
"model": "MacBook 12-inch",
"video-screensaver": {
"src": "\/videos\/mac-fall2016\/16x10\/screensaver.mov",
"width": "1152",
"height": "720"
View MHNatGeoViewControllerTransition
Pod::Spec.new do |s|
s.name = 'MHNatGeoViewControllerTransition'
s.version = '0.0.1'
s.summary = 'A new ViewController transition inspired by NatGeo City Guides by National Geographic.'
s.homepage = 'https://github.com/michaelhenry/MHNatGeoViewControllerTransition'
s.author = 'Michael Henry'
s.source = { :git => 'https://github.com/michaelhenry/MHNatGeoViewControllerTransition.git' }
s.source_files = 'MHNatGeoViewControllerTransition/*'
end
View gist:3444690
#import <RestKit/RestKit.h>
@class SMArticle
@interface SMArticleDataController : NSObject
- (void)loadArticlesWithOnLoad:(RKObjectLoaderDidLoadObjectsBlock)loadBlock onError:(RKRequestDidFailLoadWithErrorBlock)failBlock;
- (int)articleCount;
- (SMArticle*)articleAtIndex:(int)index;
View gist:3444636
NSURL* baseURL = [NSURL URLWithString:@"https://api.example.com/"];
RKObjectManager* objectManager = [RKObjectManager objectManagerWithBaseURL:baseURL];
objectManager.acceptMIMEType = RKMIMETypeJSON;
objectManager.serializationMIMEType = RKMIMETypeJSON;
[objectManager.mappingProvider setMapping:[SMArticle mapping] forKeyPath:@"article"];
[objectManager.mappingProvider
View gist:3444720
- (void)refreshArticles
{
[SVProgressHUD showWithMaskType:SVProgressHUDMaskTypeGradient];
__weak SMArticlesViewController *me = self;
[[self articlesDataSource] loadArticlesWithOnLoad:^(NSArray *newObjects) {
if (me != nil) {
[me.tableView reloadData];
[SVProgressHUD dismissWithSuccess:nil afterDelay:1];
View gist:3444638
#import "SMArticle.h"
#import <RestKit/RestKit.h>
@implementation SMArticle
@synthesize articleID,name;
+ (RKObjectMapping *)mapping {
View How not to do GCD
- (void)loadA
{
}
- (void)loadA
{
[[self aDataSource] loadAWithOnLoad:^(NSArray *newObjects) {
NSLog(@"WAIT 1");
} onError:^(NSError *error) {
UIAlertView* alert = [[UIAlertView alloc] initWithTitle:@"Error" message:[error localizedDescription] delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil];
@stevemoser
stevemoser / iOS 7 dynamic font mappings
Last active Aug 29, 2015 — forked from nuthatch/iOS 7 dynamic font mappings
What is UIFontTextStyleHeadline *really*? Dump out preferredFontForTextStyle for UIFontTextStyleHeadline, UIFontTextStyleSubheadline, UIFontTextStyleBody, UIFontTextStyleFootnote, UIFontTextStyleCaption1, UIFontTextStyleCaption2 to examine the font name, weight, and point size.
View iOS 7 dynamic font mappings
+ (void)describePreferredFonts
{
static NSArray *textStyles;
static dispatch_once_t onceToken;
dispatch_once(&onceToken, ^{
textStyles = @[UIFontTextStyleHeadline,
UIFontTextStyleSubheadline,
UIFontTextStyleBody,
UIFontTextStyleFootnote,
UIFontTextStyleCaption1,
@stevemoser
stevemoser / Trees.swift
Last active Aug 29, 2015 — forked from CodaFi/Trees.swift
A small propositional logic proof tree generator and prover.
View Trees.swift
//: Playground - noun: a place where people can play
//: Prop 'til you Drop
indirect enum Formula : CustomStringConvertible {
case Var(String)
case Or(Formula, Formula)
case And(Formula, Formula)
case Imply(Formula, Formula)
case BiImply(Formula, Formula)
case Negate(Formula)
You can’t perform that action at this time.