Skip to content

Conversation

@js-9
Copy link

@js-9 js-9 commented Oct 21, 2025

Changes

  • document how to save the incremental build cache for additional build time speedup

Checklist

  • Read the contribution guide and accept the
    code of conduct
  • Readme (updated or not needed)
  • Tests (added, updated or not needed)

Summary by CodeRabbit

  • Documentation
    • Added two new caching subsections: "Library cache" and "Incremental build cache".
    • Included sample configuration for caching the Library directory and guidance for caching the incremental build cache.
    • Clarified platform-specific path notes for Windows and that incremental cache is stored alongside the Library folder.

@github-actions
Copy link

Cat Gif

@coderabbitai
Copy link

coderabbitai bot commented Oct 21, 2025

Walkthrough

Adds two documentation subsections under Caching: "Library cache" with guidance and YAML examples for caching the Unity Library folder using actions/cache, and "Incremental build cache" with example config and platform-specific path notes (Windows path differences; incremental cache stored alongside Library).

Changes

Cohort / File(s) Summary
Documentation: caching guidance
docs/03-github/04-builder.mdx
Added "Library cache" subsection with actions/cache example and restore-keys for Unity Library folder. Added "Incremental build cache" subsection with caching example, note that incremental cache sits alongside Library, and platform-specific path guidance (Windows path differences).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 I hopped through docs to stash a cache,
Library saved in a neat little cache,
Incremental bits tucked by its side,
Windows paths noted for the ride—
Builds leap faster, joy can't hide! 🚀

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Title Check ✅ Passed The pull request title "document incremental build cache in builder docs" is directly related to the main objective of this changeset. According to the raw summary, the PR adds documentation for the incremental build cache alongside library cache documentation. While the title does not explicitly mention the library cache subsection that was also added, it clearly focuses on the primary change highlighted in the PR description: documenting how to save the incremental build cache for additional build time speedup. The title is concise, specific, and provides sufficient clarity for a teammate scanning the repository history to understand the core purpose of the changes.
Description Check ✅ Passed The pull request description follows the required template structure with all necessary sections present. The Changes section provides a clear statement about documenting how to save the incremental build cache for improved build time speedup. The Checklist section includes all required items from the template with each one marked as complete, including confirmation that the contribution guide and code of conduct were read and accepted, and that readme and test updates were addressed or deemed not needed. The description is sufficiently complete and directly aligns with the changeset objectives.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (2)
docs/03-github/04-builder.mdx (2)

113-113: Consider condensing "In order to" for better readability.

Replace "In order to make builds run faster, you can cache Library files from previous builds. To do so simply add Github Actions official" with "To make builds run faster, you can cache Library files from previous builds. Simply add Github Actions official" for more concise phrasing.

-In order to make builds run faster, you can cache Library files from previous builds. To do so
-simply add Github Actions official [cache action](https://github.com/marketplace/actions/cache)
-before any unity steps.
+To make builds run faster, you can cache Library files from previous builds. Simply add Github Actions official [cache action](https://github.com/marketplace/actions/cache)
+before any unity steps.

131-146: Documentation addition looks good, but consider expanding Windows guidance.

The new incremental build cache documentation is well-structured and includes helpful notes. However, line 146 mentions that "on Windows runners the path is different" but doesn't show an example or clarification of what that path would be. Consider adding a brief note or example for Windows users to avoid confusion.

For example, you might add a small note like:

+On Windows runners (e.g., il2cpp builds), the bee cache path differs but is still saved alongside the Library folder. Consider using a platform-agnostic pattern or absolute paths that work across runners.
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1e49e41 and c0ffa39.

📒 Files selected for processing (1)
  • docs/03-github/04-builder.mdx (2 hunks)
🧰 Additional context used
🪛 LanguageTool
docs/03-github/04-builder.mdx

[style] ~112-~112: Consider a more concise word here.
Context: ...ons tab. ## Caching ### Library cache In order to make builds run faster, you can cache L...

(IN_ORDER_TO_PREMIUM)

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

♻️ Duplicate comments (1)
docs/03-github/04-builder.mdx (1)

137-144: Verify the cache path syntax for GitHub Actions compatibility.

The cache path at line 139 uses ~/work/_temp/_github_home/.cache/unity3d/bee, which relies on shell tilde expansion. GitHub Actions cache@v3 may not reliably expand ~ in the path field since the cache action does not execute within a shell context. Previous review flagged this concern with $HOME syntax; tilde (~) has the same limitation.

For maximum compatibility, consider using a workspace-relative path or GitHub Actions environment variables. You may want to verify this path works consistently across all runner types and document any caveats.

Please confirm whether ~/work/_temp/_github_home/.cache/unity3d/bee is reliably resolved by actions/cache@v3 on all runner types, or provide the equivalent GitHub Actions expression syntax (e.g., ${{ env.HOME }}/work/_temp/_github_home/.cache/unity3d/bee).

🧹 Nitpick comments (1)
docs/03-github/04-builder.mdx (1)

113-113: Minor style improvement: use "To" instead of "In order to".

The phrase "In order to make builds run faster" can be more concise as "To make builds run faster".

Apply this diff:

- In order to make builds run faster, you can cache Library files from previous builds. To do so
- simply add Github Actions official [cache action](https://github.marketplace/actions/cache)
+ To make builds run faster, you can cache Library files from previous builds. To do so
+ simply add Github Actions official [cache action](https://github.marketplace/actions/cache)

Based on static analysis hint from LanguageTool.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c0ffa39 and 8b2a548.

📒 Files selected for processing (1)
  • docs/03-github/04-builder.mdx (2 hunks)
🧰 Additional context used
🪛 LanguageTool
docs/03-github/04-builder.mdx

[style] ~112-~112: Consider a more concise word here.
Context: ...ons tab. ## Caching ### Library cache In order to make builds run faster, you can cache L...

(IN_ORDER_TO_PREMIUM)

🔇 Additional comments (1)
docs/03-github/04-builder.mdx (1)

146-146: Clarify the Windows incremental cache path.

Line 146 states "on a windows runner... this path is different, but the incremental build cache is automatically saved with the Library folder" but provides no explicit alternative path for Windows users. This leaves Windows developers uncertain about where to find or cache the incremental build artifacts.

Please provide:

  1. The actual incremental cache path on Windows runners (e.g., something like ~\AppData\Local\Temp\... or similar).
  2. Clarification on whether Windows users should cache the same path directive or if a conditional/platform-specific approach is needed.

Alternatively, if the Windows path is identical to the Linux path (just different file separators), make that explicit.

@davidmfinol davidmfinol requested a review from Copilot October 21, 2025 20:36
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR documents how to use incremental build caching in Unity Builder to improve build performance beyond the basic library cache. It adds guidance on configuring the incremental build cache, including platform-specific considerations for Windows runners.

  • Splits the existing caching section into two subsections: Library cache and Incremental build cache
  • Adds example configuration for caching the incremental build cache directory on non-Windows runners
  • Documents that Windows runners automatically cache incremental builds with the Library folder

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

This simple addition could speed up your build by more than 50%.

### Incremental build cache
To further speedup consequent builds, you may want to cache the incremental build cache directory.
Copy link

Copilot AI Oct 21, 2025

Choose a reason for hiding this comment

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

Corrected spelling of 'speedup' to 'speed up' (two words when used as a verb).

Suggested change
To further speedup consequent builds, you may want to cache the incremental build cache directory.
To further speed up consequent builds, you may want to cache the incremental build cache directory.

Copilot uses AI. Check for mistakes.
IncrementalBuildCache-
```

On a windows runner (e.g. if building for il2cpp) this path is different, but the incremental build cache is automatically saved with the Library folder.
Copy link

Copilot AI Oct 21, 2025

Choose a reason for hiding this comment

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

Capitalize 'Windows' and 'IL2CPP' for consistency with technical naming conventions.

Suggested change
On a windows runner (e.g. if building for il2cpp) this path is different, but the incremental build cache is automatically saved with the Library folder.
On a Windows runner (e.g. if building for IL2CPP) this path is different, but the incremental build cache is automatically saved with the Library folder.

Copilot uses AI. Check for mistakes.
@davidmfinol davidmfinol self-requested a review October 21, 2025 20:37
@davidmfinol davidmfinol enabled auto-merge (squash) October 27, 2025 12:47
Copy link
Member

@davidmfinol davidmfinol left a comment

Choose a reason for hiding this comment

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

@js-9 Can you run prettier to fix the formatting? The Copilot suggestions are also valid, I think. We should be able to merge once you've updated.

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