Skip to content

Instantly share code, notes, and snippets.

View demonnico's full-sized avatar
💭
📱📱📱

Nicholas Tau demonnico

💭
📱📱📱
View GitHub Profile
@demonnico
demonnico / UIDevice+Processes.m
Created February 27, 2015 02:01
UIDevice Category For Processes.
// .h
@interface UIDevice (ProcessesAdditions)
- (NSArray *)runningProcesses;
@end
// .m
#import <sys/sysctl.h>
@implementation UIDevice (ProcessesAdditions)
@demonnico
demonnico / keybase.md
Created August 6, 2014 03:13
keybase identify

Keybase proof

I hereby claim:

  • I am demon1105 on github.
  • I am demonnico (https://keybase.io/demonnico) on keybase.
  • I have a public key whose fingerprint is 4F29 DF51 438E F0DA 6D12 325E A80B 7A46 78AB FAFA

To claim this, I am signing this object:

@demonnico
demonnico / commands.h
Created July 23, 2014 10:27
All useful commands
lipo -info hello.a // print the static library's fat info.
//get default metadata infomation from CMSampleBufferRef instance.
NSDictionary * dic =
(__bridge NSDictionary*)CMCopyDictionaryOfAttachments(NULL, imageDataSampleBuffer, kCMAttachmentMode_ShouldPropagate);
NSLog(@"default metadata:%@",dic);
//
@demonnico
demonnico / updateprovision.sh
Last active August 29, 2015 14:02
After get device's udid by udid.mobileconfig, we'd add device to profile by these steps.
/usr/libexec/PlistBuddy -c Print:UDID udid.plist
ios devices:add "name"=udid
ios profiles:devices:add profilename "name"=udid
rm -f profilename.mobileprovision
ios profiles:download profilename
@demonnico
demonnico / 0_reuse_code.js
Created May 28, 2014 10:44
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@demonnico
demonnico / .gitignore
Created May 21, 2014 12:47
git ignore file for iOS project
# Created by http://www.gitignore.io
### Xcode ###
build/
*.pbxuser
!default.pbxuser
*.mode1v3
!default.mode1v3
*.mode2v3
!default.mode2v3