BeamsChatkit 1.2.4

BeamsChatkit 1.2.4

Pusher 维护。



Pusher Beams iOS & macOS SDK

Build Status codecov Documentation CocoaPods Carthage Twitter

示例代码

构建和运行

最低要求

  • Swift 4.0+
  • Xcode - 最简单的方法是通过对 Xcode 进行购买来自 App Store,但如果你有了拥有 Apple 开发者账户的 AppleID,也可以从 developer.apple.com 下载。

安装

CocoaPods

CocoaPods 是 Cocoa 项目的依赖管理器。您可以使用以下命令来安装它:

$ gem install cocoapods

建议使用 CocoaPods 版本 1.3.1 或更高版本来构建 Pusher Beams。

要使用 CocoaPods 将 Pusher Beams 集成到您的 Xcode 项目中,请在您的 Podfile 中指定它:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '10.0'
use_frameworks!

# Replace `<Your Target Name>` with your app's target name.
target '<Your Target Name>' do
    pod 'PushNotifications', '~> 1.0.0'
end

然后,运行以下命令

$ pod install

Carthage

Carthage 是一个分权化的依赖管理器,它构建您的依赖并提供二进制框架。

建议使用 Carthage 版本 0.26.2 或更高版本来构建 Pusher Beams。

您可以使用 Homebrew 使用以下命令安装 Carthage:

$ brew update
$ brew install carthage

要使用 Carthage 将 Pusher Beams 集成到您的 Xcode 项目中,请在您的 Cartfile 中指定它:

github "pusher/push-notifications-swift"

根据您构建依赖的平台,继续遵循以下步骤

  • 如果您正在为 OS X 构建,请遵循 此指南
  • 如果您正在为 iOS、tvOS 或 watchOS 构建,请遵循 此指南

运行测试

生成测试覆盖报告

我们在本地使用 Slather 生成测试覆盖报告,并在提交拉取请求时使用 Codecov

slather coverage --html --scheme PushNotifications --workspace PushNotifications.xcworkspace/ PushNotifications/PushNotifications.xcodeproj/

open 'html/index.html'

鸣谢

Pusher Beams 由 Pusher 拥有和管理。

许可协议

Pusher Beams 在 MIT 许可下发布。有关详细信息,请参阅 LICENSE