Skip to content

Conversation

makotodejima
Copy link
Contributor

@makotodejima makotodejima commented Jun 22, 2025

This PR adds support for file selection using netrw buffer

Summary

  • Extends file manager integration to support built-in netrw file explorer
  • Adds as keybinding support in netrw buffers for adding files to Claude context
  • Supports both multiple files and single files selection

Changes Made

  • Integration: Added _get_netrw_selection() function supporting marked files and cursor-based selection
  • Extended as keybinding to work in netrw buffers
  • Compatibility: Updated diff provider and file tools to handle netrw filetype
  • Test: tests/unit/netrw_integration_spec.lua

@ThomasK33
Copy link
Member

Hey @makotodejima, thanks for the PR.

I just tried it out. I could send single files or folders to Claude Code, but sending multiple selected files does not work. In my case, it only submitted the current directory (@nvim-netrw).

Can you please look into this?

netrw.mp4

@makotodejima
Copy link
Contributor Author

hey @ThomasK33,
Thanks for checking this out. (and apologies for taking so long to get back to you)
I fixed the issue and now the multiple selection should work as expected. I would appreciate it if you could have another look.

Copy link
Member

@ThomasK33 ThomasK33 left a comment

Choose a reason for hiding this comment

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

Great. Thanks a lot for taking the time to contribute this. ❤️

@ThomasK33 ThomasK33 merged commit ac2baef into coder:main Sep 29, 2025
4 checks passed
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