Skip to content

fix(nvim): show hidden files in Snacks file picker#50

Open
hulk510 wants to merge 1 commit intomainfrom
fix/nvim-snacks-picker-hidden
Open

fix(nvim): show hidden files in Snacks file picker#50
hulk510 wants to merge 1 commit intomainfrom
fix/nvim-snacks-picker-hidden

Conversation

@hulk510
Copy link
Copy Markdown
Owner

@hulk510 hulk510 commented Apr 7, 2026

Summary

  • <leader>ff.github/ のようなドットファイルが検索できなかった問題を修正
  • Snacks.picker.fileshidden = true を渡してドットファイルを検索対象に含める
  • ignored はデフォルト(false)のままなので .gitignore は引き続き尊重される

Test plan

  • <leader>ff でドットファイル(.github/workflows/*.yml 等)が候補に出ること
  • .git/ 配下や .gitignore 対象のファイルが候補に出ないこと

🤖 Generated with Claude Code

Pass hidden = true so dotfiles like .github are searchable via <leader>ff while still respecting .gitignore.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings April 7, 2026 01:19
Copy link
Copy Markdown

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

Neovim の Snacks ファイルピッカーでドットファイル(例: .github/)が <leader>ff の検索対象に入らない問題を解消し、隠しファイルを表示できるようにする変更です。

Changes:

  • <leader>ffSnacks.picker.files() 呼び出しに hidden = true を追加してドットファイルを検索対象に含める

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

keys = {
-- ファイル検索
{ "<leader>ff", function() Snacks.picker.files() end, desc = "Find files" },
{ "<leader>ff", function() Snacks.picker.files({ hidden = true }) end, desc = "Find files" },
Copy link

Copilot AI Apr 7, 2026

Choose a reason for hiding this comment

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

<leader>ff だけ hidden = true を渡す形になったため、他の Snacks.picker.files() 呼び出し(例: dot_config/nvim/lua/plugins/dashboard.lua:29 の Dashboard の Find File)と挙動が不一致になります。ドットファイルを常に含めたい意図なら、共通のラッパー関数を作って両方から呼ぶか、Snacks の picker 側のデフォルト設定として fileshidden = true を設定して一箇所で管理するとメンテしやすいです。

Copilot uses AI. Check for mistakes.
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.

2 participants