Skip to content

feat(rg): sort by modified time#1720

Open
chaliy wants to merge 1 commit into
mainfrom
2026-05-23-rg-batch-41
Open

feat(rg): sort by modified time#1720
chaliy wants to merge 1 commit into
mainfrom
2026-05-23-rg-batch-41

Conversation

@chaliy
Copy link
Copy Markdown
Contributor

@chaliy chaliy commented May 23, 2026

What

Implement real sorting behavior for rg --sort/--sortr over recursive file candidates. --sort modified and --sortr modified now order by VFS mtime, --sort created orders by creation time, and --sort none skips the path sort.

Why

Bashkit rg previously accepted non-path sort modes but still path-sorted results. Real ripgrep supports metadata sorting, so these flags were parse-only parity gaps.

How

Carry file metadata through rg recursive candidates, centralize candidate sorting by requested sort key, bypass indexed search for non-path sorts, refresh help text, and add timed real-rg differential cases with controlled mtimes.

Risk

  • Medium
  • Recursive rg ordering changes when metadata sort flags are used. Default path sorting stays unchanged.
  • --sort accessed falls back to mtime because the current VFS metadata contract does not expose access time.

Checklist

  • Tests added or updated
  • Backward compatibility considered
  • Focused rg differential test passed
  • just pre-pr passed locally

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented May 23, 2026

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 9ff3cfc Commit Preview URL May 23 2026, 07:15 PM

@chaliy chaliy force-pushed the 2026-05-23-rg-batch-41 branch from 2072885 to 9ff3cfc Compare May 23, 2026 19:14
@chaliy
Copy link
Copy Markdown
Contributor Author

chaliy commented May 23, 2026

Temporarily closing/reopening to retrigger missing pull_request CI checks.

@chaliy chaliy closed this May 23, 2026
@chaliy chaliy reopened this May 23, 2026
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