reveal 4 for xcode 8 2017 reveal配置xcode详解

来源:互联网 发布:如何做免费网络推广 编辑:程序博客网 时间:2024/05/22 14:42
冬天时用reveal还是1.X版本。这周发现已经出来reveal 4了,用原来的方法配置已经失效了。书归正传:
step 1.打开终端, 输入命令
vim ~/.lldbinit
添加命令
command alias reveal_load_sim expr (void*)dlopen("/Applications/Reveal.app/Contents/SharedSupport/iOS-Libraries/libReveal.dylib", 0x2);

command alias reveal_load_dev expr (void*)dlopen([(NSString*)[(NSBundle*)[NSBundle mainBundle] pathForResource:@"libReveal" ofType:@"dylib"] cStringUsingEncoding:0x4], 0x2);

command alias reveal_start expr (void)[(NSNotificationCenter*)[NSNotificationCenter defaultCenter] postNotificationName:@"IBARevealRequestStart" object:nil];

command alias reveal_stop expr (void)[(NSNotificationCenter*)[NSNotificationCenter defaultCenter] postNotificationName:@"IBARevealRequestStop" object: nil nil];
这4条命令的意思如下:
reveal_load_sim 为模拟器加载reveal调试用的动态链接库
reveal_load_dev 为真机加载
reveal_start 启动reveal调试功能
reveal_stop 结束reveal调试功能



step 2.打开项目,在main函数(如图14行)找到打断点。
2.1Action 默认Debugger Command.
2.2 复制:
expr (Class)NSClassFromString(@"IBARevealLoader") == nil ? (void *)dlopen("/Applications/Reveal.app/Contents/SharedSupport/iOS-Libraries/RevealServer.framework/RevealServer", 0x2) : ((void*)0)
2.3 Options: 勾选。
step 3. 运行项目,打开reveal, 是不是发现界面有所变化。对比一下功能,你懂得。







step 4. last but not least,上链接,支持正版:https://revealapp.com/buy/
原创粉丝点击