Skip to content
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

libedit for sftp #2326

Open
jm33-m0 opened this issue Jan 29, 2025 · 4 comments
Open

libedit for sftp #2326

jm33-m0 opened this issue Jan 29, 2025 · 4 comments

Comments

@jm33-m0
Copy link

jm33-m0 commented Jan 29, 2025

Summary of the new feature / enhancement

As mentioned multiple times since 2016, sftp binary shipped with Windows is still barely usable, tab completion is not hard to implement, and upstream openssh says clearly in their documentation:

--with-libedit Enable libedit support for sftp.

But in the 2016 issue (#261) where this issue had been first raised, one contributor didn't even know if

sftp autocomplete work in the Unix version of OpenSSH?

And a collaborator said auto-completion is "provided by terminal" and closed the issue! Can you please at least do some research if you have no clue how things work?

auto complete functionality is provided by the terminals (like cygwin) and not by the sftp.
sftp protocol doesn't deal with auto complete. please use terminals that support the auto complete (like cygwin).

Not to mention sftp's auto-completion has nothing to do with "terminal", no command line editing ever had anything to do with terminal at all! I'm shocked how he can be a collaborator of this repo with such limited knowledge about openssh and unix in general.

Proposed technical implementation details (optional)

--with-libedit

when building this project

@NoMoreFood
Copy link

In fairness, it is provided by the shell if it's used prior to sftp.exe actually running. For example, if I open cmd.exe and type sftp.exe and then the next few letters of a file name, it will autocomplete when you hit tab. I know that's the functionality you are looking for, but seems like a misunderstanding rather than having "no clue how things work".

If this depends on libedit.so, I suspect someone would have to separately compile a static/dynamic binary of that library for Windows.

@jm33-m0
Copy link
Author

jm33-m0 commented Jan 30, 2025

@NoMoreFood Thanks for the reply, but I have to clear a few things.

it is provided by the shell if it's used prior to sftp.exe actually running

That's not what that issue is about, what you are trying to explain is command line auto-completion which of course is provided by the shell since the command line program is invoked by the shell. However, even with that said, the shell is not the same as the "terminal", it's not merely misunderstanding, it shows lack of knowledge of this entire area. I'm shocked because he maintains a unix package with so little understanding of basic shell/terminal knowledge, and closes a legit issue without even doing any research to understand it.

Yes we have to manually compile it with libedit support, but that's not what should happen, the feature provided by libedit is necessary for basic UX.

@mgkuhn
Copy link

mgkuhn commented Jan 30, 2025

Duplicate of issue #1986 and #2303.

@mgkuhn
Copy link

mgkuhn commented Jan 30, 2025

@jm33-m0 Where exactly did you get your libedit for Windows from when you did "manually compile it"? (Better answer at #2303 or #1986 to avoid spreading the discussion over too many different issues.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants