Skip to content

Conversation

@tdejager
Copy link
Collaborator

@tdejager tdejager commented Jan 28, 2026

Description

This adds a new crate called rattler_glob that allows globbing and hash calculations for sets of globs. We have been using this in pixi but are thinking of also using it in rattler_build. So I copied the crate and refactored it a bit with help from Claude to clean it up. I did not really change the API.

I think it's okay to go, but I put it in draft so we can take a good look at it.

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 introduces a new crate called rattler_glob that provides glob pattern matching with hash computation and modification time tracking capabilities. The crate was originally developed in pixi and has been refactored and adapted for use in the rattler ecosystem, specifically for rattler_build.

Changes:

  • Adds rattler_glob crate with comprehensive glob matching using gitignore-style patterns
  • Implements hash computation over matched files with line-ending normalization
  • Provides modification time tracking and caching for glob-based operations

Reviewed changes

Copilot reviewed 12 out of 14 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
crates/rattler_glob/Cargo.toml New crate manifest with dependencies on ignore, rattler_digest, tokio, and other workspace crates
crates/rattler_glob/src/lib.rs Main library entry point with comprehensive module documentation
crates/rattler_glob/src/glob_set/mod.rs Core glob matching implementation with rebasing support
crates/rattler_glob/src/glob_set/walk_root.rs Pattern rebasing logic for handling relative paths and computing effective walk roots
crates/rattler_glob/src/glob_set/walk.rs Directory walking implementation with hidden folder handling
crates/rattler_glob/src/glob_hash.rs Hash computation over matched files with line-ending normalization
crates/rattler_glob/src/glob_hash_cache.rs Async caching layer for glob hash computations
crates/rattler_glob/src/glob_mtime.rs Modification time tracking for matched files
tests/data/satisfiability/source-dependency/pixi.toml Test data file for glob hash computation tests
tests/data/satisfiability/source-dependency/pixi.lock Test data file for glob hash computation tests
crates/rattler_glob/src/snapshots/*.snap Insta snapshot files for testing glob hash results
Cargo.lock Updated with new ignore dependency and rattler_glob entry

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

tdejager and others added 5 commits January 28, 2026 17:28
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI commented Jan 28, 2026

@tdejager I've opened a new pull request, #2013, to work on those changes. Once the pull request is ready, I'll request review from you.

@tdejager tdejager marked this pull request as ready for review January 29, 2026 10:48
@baszalmstra baszalmstra enabled auto-merge (squash) January 29, 2026 14:45
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