-
Notifications
You must be signed in to change notification settings - Fork 318
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(context): add a ui for selecting and adding files to the sidebar as context #912
Conversation
dc661b9
to
6deb29f
Compare
Perhaps |
@brewinski Hello, I will refactor this PR on a large scale to implement |
Thanks for the feedback @yetone I looked at CodeCompanion and driving this via the markdown but couldn't get a consistent experience. This project was very helpful in working out how to get the @file callback working and integrating callbacks into mentions.lua The best I've managed to come up with is slightly closer to the Cursor experience so hopefully this is reasonable intuitive. |
…context for their sidebar session chore (context) update add type annotations to context functions chore (sidebar) remove unused notify function call refactor (sidebar) remove setting search file to file path chore (sidebar) remove nvim_notify debugging api call
…nctions and removal of the underlying selection.
7c928a4
to
79a5cb0
Compare
Great, thank you for your work! It looks very elegant now. How do I delete a selected file in this situation? |
Thank you! Currently if your cursor is over the file path you can press |
Added configurable mappings for deleting a context file & hints for updating the context from the ctx view. commit adds support for code suggestions in multiple languages. |
A small ask: can you make the choose modal as a side panel on non-float? |
@aarnphm happy to look into it. Do you have an example of what you're looking for? If you do, I'll see if I can make it work. |
Thanks @aarnphm, I'm not quite sure how this would work but id be happy if you wanted to alter the input control. I originally went with An alternative to changing the UI could be to go back to using cmp as the file picker menu as seen in this comment? |
2abbf98
to
55c17c4
Compare
@brewinski Hello, I just refactored and fixed some bugs. Now the code structure and UI/UX are more in line with my expectations. I'm ready to merge it now. Thank you so much for your hard work over the past two weeks, bringing such powerful features to avante.nvim! |
957db40
to
fef350f
Compare
This is great, thanks for your work @brewinski and @yetone to get this merged. I've been testing this over the last few hours and it's working as described. The pattern of adding files w/ I took a stab at implementing it here: I'm not married to the key binding, if there's one that makes more sense I'm happy to make that happen! |
Thank you @yetone for all the time you spent providing feedback. The refactor is looking and working great. @dogonthehorizon that's a cool idea. |
I've been playing around with some tools to allow users to add other files as context in the sidebar. So far I have something that's relatively stable and seems to work.
I'm at a point where it would be good to have some feedback on the direction I'm going with this as I'd like to make sure my work aligns with the vision of the core maintainers. As always feedback and change requests are welcome.
So far this is what I have:
Opening the context menu from the sidebar with "c" by default
Searching for files be pressing "s" in the context window by default.
Displaying the context used in the chat and saving that as part of the chat history.
Search and Replace blocks in the current file and context files.
Example Output: