remote-nvim.nvim icon indicating copy to clipboard operation
remote-nvim.nvim copied to clipboard

Allow specification of a default port to try

Open justusschock opened this issue 5 months ago • 1 comments

Is your feature request related to a problem? Please describe. My problem is that i'm working on a remote machine, where I manually need to whitelist every port that's accessed. This makes random ports quite difficult.

Describe the solution you'd like An ideal solution would be an env-var (e.g. NVIM_REMOTE_PORT=50000) that's tested when set and if not it falls back to random

Additional context I've tried implementing something like this in https://github.com/amitds1997/remote-nvim.nvim/compare/main...justusschock:remote-nvim.nvim:main?expand=1

but unfortunately the parsing doesn't work for me and I'm not sure what's going wrong/how to debug further.

justusschock avatar Jul 21 '25 18:07 justusschock

You would want to handle passing the environment variable on this line and then update the port finding script to check if that environment variable is available or not.

I would appreciate a PR if you have some bandwidth. Thanks!

amitds1997 avatar Aug 22 '25 05:08 amitds1997