Skip to content

Instantly share code, notes, and snippets.

View almostintuitive's full-sized avatar

Mark Aron Szulyovszky almostintuitive

View GitHub Profile
@alanzeino
alanzeino / lldb-debugging.md
Last active April 28, 2024 10:21
LLDB debugging with examples

LLDB Debugging Cheat Sheet

Commands

LLDB Commands

LLDB comes with a great set of commands for powerful debugging.

help

Your starting point for anything. Type help to get a list of all commands, plus any user installed ones. Type 'help for more information on a command. Type help to get help for a specific option in a command too.

@pietbrauer
pietbrauer / Makefile
Created April 26, 2015 10:03
Shutdown and reset all iOS Simulators
erase_sim:
./reset_sim.sh 2>/dev/null; true
@JadenGeller
JadenGeller / Swift Dictionary Map Filter Reduce.swift
Created March 27, 2015 04:24
Swift Dictionary Map/Filter/Reduce
extension Dictionary {
init(_ elements: [Element]){
self.init()
for (k, v) in elements {
self[k] = v
}
}
func map<U>(transform: Value -> U) -> [Key : U] {
return Dictionary<Key, U>(Swift.map(self, { (key, value) in (key, transform(value)) }))
struct PermutationSequenceGenerator<T> : GeneratorType {
var permutationSpaceGenerator: PermutationSpaceGenerator<Int>
let elements: [T]
init(elements: [T]) {
self.elements = elements
self.permutationSpaceGenerator = PermutationSpaceGenerator(objects: Array(indices(elements)))
}
@JaviLorbada
JaviLorbada / FRP iOS Learning resources.md
Last active April 8, 2024 18:07
The best FRP iOS resources.

Videos

@atsusy
atsusy / mutableArray-KVO-RACSignal.m
Last active August 29, 2015 14:04
Array insertion/deletion signal
RACSignal *s = [self rac_valuesAndChangesForKeyPath:@keypath(self, mutableArray)
options:NSKeyValueObservingOptionNew|
NSKeyValueObservingOptionOld
observer:nil];
[s subscribeNext:^(RACTuple *x){
NSLog(@"x:%@", x);
}];
self.mutableArray = [NSMutableArray new];
NSMutableArray *proxyArray = [self mutableArrayValueForKey:@keypath(self, mutableArray)];
@leeprobert
leeprobert / CollectionViewCarouselFlowLayout.m
Created March 15, 2013 11:11
UICollectionViewFlowLayout sub-class that creates layout attributes for items so they render like a carousel. The point of view is from the center of the carousel so is suited for lots of items. It also changes its behaviour based on orientation.
//
// CollectionViewCarouselFlowLayout.m
// iP2
//
// Created by Lee Probert on 07/03/2013.
//
//
#import "CollectionViewCarouselFlowLayout.h"