Skip to content

feat(nvim): add Neovim integration for Diffium#59

Merged
kubeden merged 1 commit intointerpretive-systems:mainfrom
skalwaghe-56:nvim-plugin
Oct 5, 2025
Merged

feat(nvim): add Neovim integration for Diffium#59
kubeden merged 1 commit intointerpretive-systems:mainfrom
skalwaghe-56:nvim-plugin

Conversation

@skalwaghe-56
Copy link
Contributor

Summary

Adds a functional Neovim plugin for launching Diffium in a terminal.

Linked Issue(s)

Closes #14.

Checklist

  • I am assigned to the linked issue(s)
  • I wrote tests or updated existing tests
  • I ran go build and go test ./...
  • I updated docs/README if needed

@kubeden
Copy link
Contributor

kubeden commented Oct 5, 2025

Hey! This is exactly the direction I've been looking for :)

However I noticed one little problem with the functionality of it:
image

When it's opened (exactly as it should), I notice I can't exit it.

Please make sure that if the user types q it will exit Diffium, and also if the user types :Diffium close in nvim input mode, it will also close Diffium

@kubeden kubeden self-requested a review October 5, 2025 08:40
@skalwaghe-56
Copy link
Contributor Author

@kubeden It exits. I have tested it and yes it does exit. Can you please check that the focus of the Diffium windows is not lost in nvim? If so it wont work. But if the focus is there it should exit. I request you to please check that again.

@skalwaghe-56
Copy link
Contributor Author

Screencast.From.2025-10-05.14-25-25.mp4

@skalwaghe-56
Copy link
Contributor Author

@kubeden I request you to watch the attached video. You can see there that I am able to exit Diffium by pressing q. Just make sure that the window (diffium window) does not lose focus if it does you can just focus on it back again by pressing i. I request you to check it once again and let me know! Thanks!

@skalwaghe-56
Copy link
Contributor Author

Also, in your image I can see in the bottom left that nvim is showing help to exit that means that the diffium window lost focus and your q was captured by nvim which caused it to give that message. Please try as I told previously and let me know if you still face any issues! Thanks!

@kubeden
Copy link
Contributor

kubeden commented Oct 5, 2025

Yeah, I can see it works from your video. Here's my testing though :? when I click q inside diffium, it attempts to close it, but I think the buffer stays. When I do :q it does close it, but otherwise it stays blank.

Screen.Recording.2025-10-05.at.12.05.26.mov

@kubeden
Copy link
Contributor

kubeden commented Oct 5, 2025

not a buffer* a modal.. I'm not sure how the "modals" are called in nvim lol

@skalwaghe-56
Copy link
Contributor Author

Hmm, that's interesting. I see you're using macos, idk what's causing this behaviour?

@skalwaghe-56
Copy link
Contributor Author

Also, why is the repo showing as not participating in hacktoberfest site?
image

@kubeden
Copy link
Contributor

kubeden commented Oct 5, 2025

on your second question: I just added the hacktoberfest topic + I will add the hacktoberfest-accepted label when this is done

no your first question: I am using MacOS, and please do try to explore the code you wrote. I can assume the issue comes from a logic inside the q command inside Diffium, not in your nvim integration. Probably, in some way, pass a message to close the modal in case Diffium has been called in nvim mode :)

@skalwaghe-56
Copy link
Contributor Author

@kubeden I investigated a little bit on why this might happen. And found a link can you try adding a code snippet in the diffium.lua and then test for me please?

@kubeden
Copy link
Contributor

kubeden commented Oct 5, 2025

Hey um sure. What code snipped would you like me to add? You can add it up as a commit here

@skalwaghe-56
Copy link
Contributor Author

@kubeden Can you check now? I have pushed the code. Sorry for the late response.

@skalwaghe-56
Copy link
Contributor Author

@kubeden Also, please add the hacktoberfest-accepted label to the PR. Thanks!

@kubeden
Copy link
Contributor

kubeden commented Oct 5, 2025

Great! That works well now. Good job.

@kubeden kubeden merged commit 267cda9 into interpretive-systems:main Oct 5, 2025
@skalwaghe-56 skalwaghe-56 deleted the nvim-plugin branch October 5, 2025 12:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[feat] diffium as a nvim plugin... i don't know how

2 participants