如何将 .plist 文件添加到 Xcode 中的所有目标? [英] How to add .plist file to all targets in Xcode?

查看:39
本文介绍了如何将 .plist 文件添加到 Xcode 中的所有目标?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对 iOS 完全陌生,但我目前正在尝试设置 Google Analytics.我遵循了SDK 文档一切都很顺利,直到这一步:

Totally new to iOS but I'm currently trying to setup Google Analytics. I have followed the SDK documentation and everything went great until this step:

将配置文件添加到您的项目

将刚刚下载的 GoogleService-Info.plist 文件拖到 Xcode 项目的根目录中,并将其添加到所有目标中.

Drag the GoogleService-Info.plist file you just downloaded into the root of your Xcode project and add it to all targets.

它没有说明如何将其添加到所有目标.作为 Xcode 和 iOS 的新手,我完全迷失了方向.有人给我答案吗?

It doesn't say anything on HOW to add it to all targets. Being new to Xcode and iOS in general, I'm completely lost. Anyone with an answer for me?

谢谢!

推荐答案

在项目导航器中选择 GoogleService-Info.plist(Xcode 左侧的文件层次结构).然后,如果它尚未打开,打开实用工具栏(单击 Xcode 中最右上角的按钮).您将看到目标会员"部分.选中所有复选框以将 .plist 添加到所有目标.

Select the GoogleService-Info.plist in the project navigator (the file hierarchy on the left side of Xcode). Then, if it isn't open yet, open the utilities bar (click the top-right most button in Xcode). You will see a section 'Target Membership'. Check all the checkboxes to add the .plist to all targets.

在大多数情况下,只需将文件添加到您的项目中即可.

In most cases it is enough to just add the file to your project.

这篇关于如何将 .plist 文件添加到 Xcode 中的所有目标?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆