Skip to content

feat(rg): support glob character classes - #1703

Merged
chaliy merged 1 commit into
mainfrom
2026-05-22-rg-batch-24
May 23, 2026
Merged

chaliy merged 1 commit into
mainfrom
2026-05-22-rg-batch-24

Conversation

@chaliy

@chaliy chaliy commented May 23, 2026

Copy link
Copy Markdown
Contributor

What

Add bracket character class support to rg glob matching.

Why

Real ripgrep accepts glob classes such as [ab].txt and uses them in built-in type definitions like make.

How

  • Teach rg glob-to-regex conversion to handle positive and negated bracket classes.
  • Switch make type defaults to real ripgrep bracket-class globs.
  • Add real-rg differential coverage for --glob, --type-add, and make type behavior.

Risk

  • Low
  • Affects rg glob filtering, ignore/pre-glob matching, and type glob matching.

Checklist

  • Tests added or updated
  • Backward compatibility considered

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
bashkit b9c6bf3 Commit Preview URL May 23 2026, 02:56 AM

@chaliy
chaliy merged commit 704ea2a into main May 23, 2026
34 checks passed
@chaliy
chaliy deleted the 2026-05-22-rg-batch-24 branch May 23, 2026 03:08
chaliy added a commit that referenced this pull request May 30, 2026
## What
Add bracket character class support to rg glob matching.

## Why
Real ripgrep accepts glob classes such as [ab].txt and uses them in
built-in type definitions like make.

## How
- Teach rg glob-to-regex conversion to handle positive and negated
bracket classes.
- Switch make type defaults to real ripgrep bracket-class globs.
- Add real-rg differential coverage for --glob, --type-add, and make
type behavior.

## Risk
- Low
- Affects rg glob filtering, ignore/pre-glob matching, and type glob
matching.

## Checklist
- [x] Tests added or updated
- [x] Backward compatibility considered
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.

1 participant