Skip to content

CPLAT-10756: fuzzy-search URL menu + newest-first timestamps for urls/files/changes#65

Merged
gavin-jeong merged 1 commit into
masterfrom
CPLAT-10756-urls-fuzzy-timestamps
Jul 9, 2026
Merged

CPLAT-10756: fuzzy-search URL menu + newest-first timestamps for urls/files/changes#65
gavin-jeong merged 1 commit into
masterfrom
CPLAT-10756-urls-fuzzy-timestamps

Conversation

@gavin-jeong

Copy link
Copy Markdown
Collaborator

JIRA: https://sendbird.atlassian.net/browse/CPLAT-10756

Two related follow-ups to the status-aware URL menus (#64).

1. Fuzzy search in the TUI URL menu

filterURLItems previously required each whitespace-separated term to be a substring. Now each term fuzzy-matches (its chars appear in order) via the existing fuzzyMatch helper — matching the project picker's search feel:

  • grui finds internal/gui
  • space-joined terms narrow further

2. Timestamps + newest-first ordering for all scopes (urls / files / changes)

The most recently referenced item now shows first, and every row carries a relative time.

  • extract.Item gains a Timestamp field. EntryURLs and SessionFilePaths stamp each item with the latest entry it appeared in and sort most-recent first (sortItemsByTime). Single-message Block* scopes leave it zero (no entry context).
  • changes already carried timestamps; its sort switches from path order to newest-first (sortChangesByTime) for consistency.
  • TUI: URL/file rows render a dim timeAgo suffix (change rows already embed one in their label).
  • CLI picker: URL/file items sorted newest-first with a shortTimeAgo suffix (sortAndStampItems), matching the changes picker.
  • --plain: timestamp appended as a trailing 4th tab column, so existing 3-column parsers keep working while order reflects recency.

Testing

  • New extract tests: EntryURLs recency + timestamp refresh, block-scope zero timestamp, file-path recency stamping.
  • go build ./..., go test ./internal/extract/ ./internal/cli/ ./internal/tui/ ./internal/session/ all green.
  • Verified ccx urls --plain / ccx files --plain emit the 4th timestamp column, newest-first.

Notes

Builds on #64 (now merged to master); this branch is cut from master and contains only the fuzzy + timestamp changes.

…changes

JIRA: https://sendbird.atlassian.net/browse/CPLAT-10756

Two related follow-ups to the status-aware URL menus:

1. Fuzzy search in the TUI URL menu. filterURLItems previously required each
   whitespace term to be a substring; now each term fuzzy-matches (chars in
   order) via the existing fuzzyMatch helper, matching the project picker's
   search feel — "grui" finds "internal/gui", space-joined terms narrow.

2. Timestamps + newest-first ordering for all three scopes (urls, files,
   changes), so the most recently referenced item shows first and every row
   carries a relative time.
   - extract.Item gains a Timestamp field. EntryURLs and SessionFilePaths now
     stamp each item with the latest entry it appeared in and sort most-recent
     first (sortItemsByTime); Block* single-message scopes leave it zero.
   - changes already carried timestamps; its sort switches from path order to
     newest-first (sortChangesByTime) for consistency.
   - TUI: URL/file rows render a dim timeAgo suffix (change rows already embed
     one in their label).
   - CLI picker: URL/file items sorted newest-first with a shortTimeAgo suffix
     (sortAndStampItems), matching the changes picker.
   - `--plain` output appends the timestamp as a trailing 4th tab column, so
     existing 3-column parsers keep working while order reflects recency.

Covered by new extract tests (EntryURLs recency + refresh, block-scope zero
timestamp, file-path recency stamping).

@jinsekim jinsekim left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM!

@jinsekim jinsekim added the auto-review/approved Auto-approved by the Slack auto-reviewer bot label Jul 9, 2026

@jinsekim jinsekim left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM!

@gavin-jeong gavin-jeong merged commit dba94c4 into master Jul 9, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-review/approved Auto-approved by the Slack auto-reviewer bot

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants