Page 1 of 1

Symlinks on SFTP

Posted: 2023-05-09, 19:19 UTC
by Unused
When i show the contents of a folder on a Linux host where i connected via SFTP Plugin, the symlink icons are visible as files. Is there some way to display them as the target type? For example, when the symlink target is a folder, display it as a folder (and sort it as folder), if the target of the symlink is a file, use the file icon...

Re: Symlinks on SFTP

Posted: 2023-05-09, 19:27 UTC
by ghisler(Author)
You can't see from the directory listing whether a symlink points to a file or a folder. That's why they are shown as files - when you then try to open them, the plugin will resolve the symlink and see whether it points to a file or folder.

Re: Symlinks on SFTP

Posted: 2023-05-09, 19:35 UTC
by Unused
Can you please try to add this as a feature request? At least i have seen this working in Ghost Commander. But i would like to use Total Commander. It has the better handling for favorites and some more things.

Re: Symlinks on SFTP

Posted: 2023-05-09, 19:40 UTC
by ghisler(Author)
I'm not aware of an easy way to add this. The plugin would have to visit each target just to check whether it is a file or a folder. When there are, say, 10'000 symlinks in one folder, it would mean 10'000 requests to the server.

Re: Symlinks on SFTP

Posted: 2023-05-09, 20:02 UTC
by Unused
I have no idea, if you get back a single object with all the fs entries in it or you get back a object per fs entry. If the first is the case, maybe there is a way to update the object with the needed info, before you send the reponse. If the later is the case > mostly there are only a handfull symlinks in a directory. Personally i use them a lot (I dont use Windows anymore, since Windows 11 as released) on Desktop (Arch) and Server (Debian). But i have never more than 10 symlinks in the current directory. But its your app. Its only a small wish/request.

Re: Symlinks on SFTP

Posted: 2023-05-10, 14:00 UTC
by ghisler(Author)
It's like you logged into the server via SSH secure shell and issued a few ls -l commands - they don't tell you whether the target is a file or a folder. Or is there an ls parameter to get this information?

Re: Symlinks on SFTP

Posted: 2023-05-10, 16:01 UTC
by Unused
What's with

Code: Select all

ls -lL
or

Code: Select all

ls -lF
. In the last case, this adds a / to the target, if the target is a directory.

Re: Symlinks on SFTP

Posted: 2023-05-11, 08:29 UTC
by ghisler(Author)
I will try it, thanks!