Skip to content

Instantly share code, notes, and snippets.

View josephlord's full-sized avatar

Joseph Lord josephlord

View GitHub Profile
@josephlord
josephlord / console_log
Last active December 14, 2015 13:29
--autolibs=0 fails with OpenSSL issues but without a useful error message. Run as test user only used for testing RVM on OS X. System has no installed package manager. Zsh is installed in the system but not used by this user. --autolibs=3 seems to work and installs Homebrew.
rvm 1.18.15 (stable) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/]
jl-mbp:~ test$ rvm get head
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 185 100 185 0 0 68 0 0:00:02 0:00:02 --:--:-- 78
100 11525 100 11525 0 0 2947 0 0:00:03 0:00:03 --:--:-- 68195
Downloading RVM from wayneeseguin branch master
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
@josephlord
josephlord / schedule.rb
Last active December 23, 2015 09:09
Dashboard schedule move/create task/task_group API
params: {
regular schedule element params: (name / description etc.) ...
create_task_group: {
task_group: {task group object},
tg_position: y
},
move_task_group: {
at_position: x,
@interface UILabel (dynamicSizeMe)
-(float)resizeToFit;
-(float)expectedHeight;
-(void)resizeToStretch;
-(float)expectedWidth;
@end
@josephlord
josephlord / UIPopoverCrash-highlights.crash
Last active August 29, 2015 13:57
Fast Lists - UIPopover dismissal crash key part
Incident Identifier: 5B3015C5-1579-467E-8CED-F134172C5FBE
CrashReporter Key: [REMOVED]
Hardware Model: iPhone OS,7.0.2
Process: Fast Lists [215]
Path: /var/mobile/Applications/FD6CA89D-8176-4AD9-B65C-8A5B3DB25705/Fast Lists.app/Fast Lists
Identifier: com.human-friendly.Fast-Lists
Version: 2.04
Code Type: ARM (Native)
Parent Process: launchd [1]
@josephlord
josephlord / gist:9687588
Created March 21, 2014 14:34
Full crash report for Fast Lists UIPopover dismissal issue
Incident Identifier: 5B3015C5-1579-467E-8CED-F134172C5FBE
CrashReporter Key: [REMOVED]
Hardware Model: iPhone OS,7.0.2
Process: Fast Lists [215]
Path: /var/mobile/Applications/FD6CA89D-8176-4AD9-B65C-8A5B3DB25705/Fast Lists.app/Fast Lists
Identifier: com.human-friendly.Fast-Lists
Version: 2.04
Code Type: ARM (Native)
Parent Process: launchd [1]
Frame No Funciton address
Binary Method and position in method
0 libobjc.A.dylib 0x3a003b26 objc_msgSend + 6
1 UIKit 0x322bfb13 __73-[UIPopoverController _completionBlockForDismissalWhenNotifyingDelegate:]_block_invoke + 327
2 UIKit 0x320aafe9 -[UIViewAnimationBlockDelegate _didEndBlockAnimation:finished:context:] + 285
3 UIKit 0x320aac37 -[UIViewAnimationState sendDelegateAnimationDidStop:finished:] + 179
4 UIKit 0x320aab4f -[UIViewAnimationState animationDidStop:finished:] + 71
5 QuartzCore 0x31d02d09 CA::Layer::run_animation_callbacks(void*) + 233
6 libdispatch.dylib 0x3a4ebd67 _dispatch_client_callout + 23
7 libdispatch.dylib 0x3a4f27c1 _dispatch_main_queue_callback_4CF$VARIANT$mp + 269
@josephlord
josephlord / objc_msgSend
Last active August 29, 2015 13:57
The start of objc_msgSend
libobjc.A.dylib`objc_msgSend:
cbz r0, 0x38f86b5e ; objc_msgSend + 62
ldr.w r9, [r0]
ldrh.w r12, [r9, #12] ;<<<< This is the line that crashes
ldr.w r9, [r9, #8]
and.w r12, r12, r1
add.w r9, r9, r12, lsl #3
ldr.w r12, [r9]
teq.w r12, r1
Thread 0 crashed with ARM (Native) Thread State:
pc: 0x3a003b26 r7: 0x27dc5d40 sp: 0x27dc5d28 r0: 0x185c0670
r1: 0x3265f920 r2: 0x1810b4d0 r3: 0x00000002 r4: 0x1810b4d0
r5: 0x185c0670 r6: 0x3266a294 r8: 0x181088b0 r9: 0xc185af39
r10: 0x00000001 r11: 0x3ac40a34 r12: 0x3ab3a224 lr: 0x32260013
cpsr: 0x20000030
@josephlord
josephlord / arrays.swift
Last active August 29, 2015 14:04
Swift Arrays Beta 3 (basics)
var a = [1,2,3]
var b = a
a == b // true
a === b // true
b[0] = 10
a // [1,2,3]
b // [10,2,3]
b[0] = 1
a == b // true
a === b // false
@josephlord
josephlord / newArraySyntax.swift
Last active August 29, 2015 14:04
Swift Arrays Beta 3 (syntax)
// Note in Swift you usually don't have to state the type it can be inferred but it is useful to be able to do so if you are assigning an empty collection. It can also be necessary in function declarations.
// Beta 1 and 2
var c:Int[] = []
// No way of specifiying type really just create the instance of the generic and let type inference define the type of d.
var d = Dictionary<Int:String>()
// Beta 3
var c:[Int] = []