这是对官方教程的补充

To add RAC to your application:

  1. Add the ReactiveCocoa repository as a submodule of your application's repository.
    1. 首先你得有个git,给自己的工程创建一个git
    2.   
      $ git submodule add https://github.com/ReactiveCocoa/ReactiveCocoa.git external/ReactiveCocoa
      $ git add .gitmodules external/ReactiveCocoa
      $ git commit -m "Add ReactiveCocoa as a submodule"
  2. Run script/bootstrap from within the ReactiveCocoa folder.
    1.   这里需进入sh(只需在终端键入"sh")
    2. cd 到脚本所在目录,键入脚本文件名即可
  3. Drag and drop ReactiveCocoaFramework/ReactiveCocoa.xcodeproj into your application's Xcode project or workspace.
  4. On the "Build Phases" tab of your application target, add RAC to the "Link Binary With Libraries" phase.
    • On iOS, add libReactiveCocoa-iOS.a.(我没找到这个东西,于是添加了ReactiveCocoa.framework)
    • On OS X, add ReactiveCocoa.framework. RAC must also be added to any "Copy Frameworks" build phase. If you don't already have one, simply add a "Copy Files" build phase and target the "Frameworks" destination.
  5. Add "$(BUILD_ROOT)/../IntermediateBuildFilesPath/UninstalledProducts/include" $(inherited)to the "Header Search Paths" build setting (this is only necessary for archive builds, but it has no negative effect otherwise).
  6. For iOS targets, add -ObjC to the "Other Linker Flags" build setting.
  7. If you added RAC to a project (not a workspace), you will also need to add the appropriate RAC target to the "Target Dependencies" of your application.

If you would prefer to use CocoaPods, there are some ReactiveCocoa podspecs that have been generously contributed by third parties.(系统假如已经安装了CocoaPods会很方便,但是安装cocoapod的过程中是有些坑的。教程自行谷歌。本文过程中没有使用cocoapod。)

To see a project already set up with RAC, check out C-41 or GroceryList, which are real iOS apps written using ReactiveCocoa.

在项目中添加ReactiveCocoa #安装与配置的更多相关文章

  1. 如何在VUE项目中添加ESLint

    如何在VUE项目中添加ESLint 1. 首先在项目的根目录下 新建 .eslintrc.js文件,其配置规则可以如下:(自己小整理了一份),所有的代码如下: // https://eslint.or ...

  2. VS2015 项目中 添加windows服务

    1. 在项目中添加winows服务 今天刚刚为自己的项目添加了windows服务,以服务的形式运行后台系统,为前端提供接口服务,下面说一下具体怎么为vs项目添加windows服务 2. 添加Windo ...

  3. 在SpringBoot项目中添加logback的MDC

    在SpringBoot项目中添加logback的MDC     先看下MDC是什么 Mapped Diagnostic Context,用于打LOG时跟踪一个“会话“.一个”事务“.举例,有一个web ...

  4. web项目中添加logger日志

    在项目中添加log4j.xml文件 log4j.xml文件 <?xml version="1.0" encoding="UTF-8" ?><! ...

  5. 初识quartz 并分析 项目中spring整合quartz的配置【原创+转载】

    初识quartz 并分析 项目中spring整合quartz的配置[原创+转载]2018年01月29日 12:08:07 守望dfdfdf 阅读数:114 标签: quartz 更多个人分类: 工具 ...

  6. Entity Framework 的小实例:在项目中添加一个实体类,并做插入操作

    Entity Framework 的小实例:在项目中添加一个实体类,并做插入操作 1>. 创建一个控制台程序2>. 添加一个 ADO.NET实体数据模型,选择对应的数据库与表(Studen ...

  7. 关于如何正确地在android项目中添加第三方jar包

    在android项目中添加第三方jar包虽然不是一个很复杂的问题,但是确实给很多开发者带来了不小的困扰.我自己就曾经碰到过calss not found exception.error inflati ...

  8. 给iOS项目中添加图片,并通过UIImageView引用和显示该UIImage图片

    [问题] 关于iOS/iPhone中的文件选择对话框,用于用户去选择图片等文件 过程中,问题转换为,需要给当前iOS项目中,添加一个图片. 类似于Windows开发中的资源文件,其中图片文件属于资源的 ...

  9. Intellij IDEA在maven项目中添加外部Jar包运行

    一. 问题概述 我们知道Intellij IDEA是非常好用的Java语言开发的集成环境.提供了非常多实用的功能,包括了智能代码助手.代码自动提示.代码重构.各种插件等,当然也集成了maven 正常情 ...

随机推荐

  1. tr:even 与tr:odd

    :even匹配所有索引值为偶数的元素,从 0 开始计数查找表格的1.3.5...行(即索引值0.2.4...)<table> <tr><td>Header 1< ...

  2. 使用PerfView诊断.Net GC的问题

    PerfView 概述: PerfView是一个可以帮助你分析CPU和内存问题的工具软件.它非常轻量级也不会入侵诊断的程序,在诊断过程中对诊断的程序影响甚微. Visual Studio自带的性能分析 ...

  3. smb:unrecognized service

    [root@sycflash ~]#service smb status smb:unrecognized service 提示:smb:unrecognized service.这时你会按照常规的方 ...

  4. hive导入数据

    替换分隔符为\ sed -i 's/\t/\x1/g;s/;/\x1/g' test1.txt gz压缩 gzip -r test1.txt 查看文件 hdfs dfs -ls /hive/wareh ...

  5. MonkeyRunner测试一MonkeyRunner的使用

    最近搭建MonkeyRunner开发环境,安装PyDev时,饱受折磨,现在终于搞定.因为一些原因,用了JDK1.6,在线安装插件PyDev成功后,Windows-Preferences里找不到PyDe ...

  6. 在树莓派2代B型/3代 上安装Fedora23 - Installing Fedora 23 on Raspberry Pi 2 model B or Raspberry Pi 3

    本文主要用于记录安装过程,以便日后查阅回顾. 之前在自己的树莓派上运行的一直是通过NOOB安装的Raspbian,但是本人平时更喜欢用Fedora作为开发和使用环境,而且Raspbian上的软件包通常 ...

  7. 习课省市区的三级联动(cxselect的使用)

    1,api:http://www.jq22.com/jquery-info32382,demo:http://blog.csdn.net/luo201227/article/details/38844 ...

  8. DOM杂记

    INPUT 监听输入框值的变化:"input"

  9. window 10 用composer安装 基于 Laravel 5.3 的 Coaster CMS Curl错误77解决

    安装教程来自 http://laravelacademy.org/post/6547.html 1.系统环境windows 10 nodejs3.9.2 composer1.2.4(国内镜像) Cmd ...

  10. 解决sublime3 package control显示There are no packages available for installation

    之前一直是在windows上使用sublime,由于公司内部搭建了服务器,干脆把所有项目搬到了服务器上,自然也装上了牛逼闪闪的sublime,然而在接下来安装插件的时候却出了问题,package co ...