Skip to content

Conversation

ncooke3
Copy link
Member

@ncooke3 ncooke3 commented Oct 6, 2025

The Firestore bits of the Package.swift are justifiably complicated. I vibe coded these docs to explain the current state.

cc: @rafikhan

#no-changelog

Copy link
Contributor

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

@ncooke3
Copy link
Member Author

ncooke3 commented Oct 6, 2025

/gemini review These docs are meant to educate repo maintainers on the organization of the Firestore-related targets in the Package.swift

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds excellent documentation explaining the complex Swift Package Manager target hierarchy for Firestore. The document is well-structured and clearly explains the different build options (binary, source, and CI-local) and the testing setup. I have a couple of minor suggestions to improve consistency and clarity in the dependency diagrams and target descriptions. Overall, this is a great addition that will be very helpful for developers.

Comment on lines +67 to +68
* **`FirebaseFirestoreTarget`**: A wrapper target, same as in the source-based
build.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

low

This description makes a forward reference to the "source-based build" section, which appears later in the document. It would be clearer to provide a self-contained description to improve readability.

Suggested change
* **`FirebaseFirestoreTarget`**: A wrapper target, same as in the source-based
build.
* **`FirebaseFirestoreTarget`**: The wrapper target that provides a stable entry point for clients.

Comment on lines +102 to +103
├── gRPC-cpp (source) (from https://github.com/grpc/grpc-ios.git)
└── BoringSSL (source) (from https://github.com/firebase/boringSSL-SwiftPM.git)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

low

The dependency hierarchies for binary and source builds are slightly inconsistent. The source-based build hierarchy includes BoringSSL, which is a transitive dependency of gRPC-cpp, while the binary-based build hierarchy appears to only list direct dependencies. To make the diagrams consistent and easier to understand, it's better to only show direct dependencies in both. This change removes the transitive BoringSSL dependency from this diagram and updates the tree structure accordingly.

Suggested change
├── gRPC-cpp (source) (from https://github.com/grpc/grpc-ios.git)
└── BoringSSL (source) (from https://github.com/firebase/boringSSL-SwiftPM.git)
└── gRPC-cpp (source) (from https://github.com/grpc/grpc-ios.git)


## 2. Source-Based Build

When the `FIREBASE_SOURCE_FIRESTORE` environment variable is set, Firestore and
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we document how to set FIREBASE_SOURCE_FIRESTORE since, correct me if I'm wrong, this can only be set before launching Xcode. I haven't tried setting FIREBASE_SOURCE_FIRESTORE in the Environment Variables for the scheme and then running "Reset Package Caches" but I'm fairly sure that wouldn't work.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a great suggestion! Will do.

daymxn
daymxn previously approved these changes Oct 6, 2025
Copy link
Member

@daymxn daymxn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left some nits, but otherwise lgtm.

Is this something we'd wanna link to from other docs? Like Firestore/README.md?

options for Firestore: from source or from a pre-compiled binary. This choice is
controlled by the `FIREBASE_SOURCE_FIRESTORE` environment variable.

## Main Product
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Why did it capitalize every word in each header?

Suggested change
## Main Product
## Main product


## Main Product

The main entry point for integrating Firestore via Swift Package Manager is the
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: The repetition of "Swift Package Manager" throughout the docs is a bit verbose.

Suggested change
The main entry point for integrating Firestore via Swift Package Manager is the
The main entry point for integrating Firestore via SPM is the

daymxn

This comment was marked as outdated.

@daymxn daymxn dismissed their stale review October 6, 2025 20:18

Changing to a comment instead of a +2, so you can enable auto merge and have @cherylEnkidu approve it instead

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants