gitui-org / gitui-org/gitui

Feature Request: Built-in text/content search across files

オープン
#2,964 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
Rust
スター
22.5k
フォーク
773
PR マージ指標
30日以内にマージされた PR はありません

説明

## Feature Request

**Summary:**
GitUI currently does not provide a built-in way to search for text or content across files in a repository. Users who want to find a specific string, pattern, or piece of code must leave the GitUI interface and use an external tool (e.g. `grep`, `rg`, or their editor's search).

**Expected Behavior:**
GitUI should include a built-in file content search (similar to `grep` / `ripgrep`) that allows users to:
- Enter a search query (plain text or regex)
- See matching files and line previews directly within the TUI
- Navigate to a specific match in context

**Why This Matters:**
Code review and diff inspection workflows often require looking up where a symbol or string is used across the repository. Having to switch out of GitUI to a separate terminal search breaks the flow and reduces the tool's usefulness as a self-contained Git UI.

**Possible Approach:**
- Add a dedicated search panel (e.g. reachable via a keybinding like `/` or a dedicated shortcut)
- Internally delegate to `git grep` or an optional `ripgrep`/`grep` backend
- Display results in a scrollable list with file path, line number, and a snippet of the matching line
- Allow jumping into the diff/file view from a result

**Alternatives Considered:**
- Using `git grep` manually in a separate terminal — works but requires context switching
- Using editor search — not available when GitUI is the primary interface

**References:**
- Similar feature in other TUI Git clients (e.g. lazygit's filter/search capabilities)

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

ファイルやテストは特定されていないため、まず既存のTUIエントリーポイントにあるキーバインド、パネル、diff/ファイルビューを調査します。提案されている `/` ショートカットを中心に検索パネルを定義し、`git grep` またはオプションのripgrep/grepバックエンドを評価します。ユーザーがテキストまたはregexを検索し、行プレビュー付きでファイルパスを閲覧し、コンテキスト内の一致箇所に移動できれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
git, rust
領域
cli, devtools, search
issue の種類
機能追加
難易度
5/5
見積もり時間
1週間以上
活発さ
静か
明瞭さ
おおむね明確
初心者へのやさしさ
42/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。