Version License Platform

Actions Status

GoogleUtilities

GoogleUtilities 为 Firebase 和其他 Google SDK 提供了一系列在 Apple 平台进行开发时可用的实用工具。

这些实用工具不直接支持非 Google 库的使用。

集成测试

以下说明适用于次要版本和补丁版本的更新。主版本需要定制化的适配。

CI 变为绿色后

发布

发布流程如下:

  1. 为 Swift PM 标记和发布
  2. 发布到 CocoaPods
  3. 创建 GitHub Release
  4. 执行发布后清理

Swift Package Manager

通过为 Swift PM 创建并推送标签,新标记的版本将立即发布以供公众使用。 鉴于此,请验证 Swift PM 的预期发布时间。

git tag {version}
git push origin {version}

注意:确保任何依赖于新的 GoogleUtilities 版本的进行中的 PR 都已更新为指向新标记的版本,而不是校验和。

CocoaPods

创建 GitHub Release

使用最新版本更新发布模板Tag versionRelease title 字段。 此外,在发布的描述中引用发行说明

有关示例,请参见此版本

不要忘记执行发布后清理

发布后清理

清理 SpecsStaging
pwd=$(pwd)
mkdir -p /tmp/release-cleanup && cd $_
git clone git@github.com:firebase/SpecsStaging.git
cd SpecsStaging/
git rm -rf GoogleUtilities/
git commit -m "Post publish cleanup"
git push origin master
rm -rf /tmp/release-cleanup
cd $pwd

开发

要在此仓库中进行开发,请确保您至少拥有以下软件:

对于您要开发的 pod

pod gen GoogleUtilities.podspec --local-sources=./ --auto-open --platforms=ios

注意:如果 CocoaPods 缓存已过期,您可能需要在运行 pod gen 命令之前运行 pod repo update

注意:将 --platforms 选项设置为 macostvos 以开发/测试这些平台。 从 10.2 开始,Xcode 无法正确处理多平台 CocoaPods 工作区。

Catalyst 开发

或者,在每个目标中禁用签名

代码格式化

为确保代码格式一致,请在创建 PR 之前运行脚本 ./scripts/check.sh

GitHub Actions 将验证任何代码更改是否以符合样式的方式完成。 安装 clang-formatmint

brew install clang-format@18
brew install mint

运行单元测试

选择一个 scheme 并按 Command-u 来构建一个组件并运行其单元测试。

贡献

请参阅贡献

许可

本仓库的内容在 Apache License, version 2.0 许可下发布。