Hardlinks and Junctions

We welcome any suggestions for new features or improvements in Altap Salamander. Please post one suggestion per report.
User avatar
SvA
Posts: 483
Joined: 29 Mar 2006, 02:41
Location: DE

Hardlinks and Junctions

Post by SvA »

Mystico's request for virtual folders caused me to search for the ability to create hardlinks and junctions. But I could not find it in Servant Salamander.

I used to create hardlinks from the command line and it never appeared to me, that it was so much more comfortable and easy create from within Salamander.

Hardlinks and junctions overlap somewhat with Mysico's idea of a virtual folder but are restricted to the same volume. On the other hand these file system objects appear to the whole system as real files and folders, not just to Salamander.
User avatar
zarevak
Plugin Developer
Plugin Developer
Posts: 789
Joined: 04 Feb 2006, 16:49
Location: Prague, Czech Republic

Post by zarevak »

Hi,
just a summary from Czech thread about similar topic Full linkovanie na NTFS - "Junction point":
- creating Junction Points
- viewing Junction Point links (to be able to see, where the link goes)
- editing Junction Points (to be able to change the link target)
similar functionality would be needed for Hardlinks...

From another (Deleting a NTFS hardlink/junction) topic:
- plan to change Delete command to Unlink for Junction Points


Temporarily you can use MakeLink.exe from Mike Nordell hosted on The Code Project along with sourcecode
Usage:
makelink empty_folder target - creates Junction point from empty_folder to target
makelink /L junction_point - show the Junction point target
makelink /D junction_point - unlinks Junction point


For using in SS (at least 2.5RC1) you can add UserMenu item:

Code: Select all

Command: MakeLink.exe
Arguments: $(DirToCompareActive) $(DirToCompareInactive)
Initial directory: $(FullPath)
I suggest to uncheck "Close shell window" to see potential error messages.
Petr Solin
ALTAP Staff
ALTAP Staff
Posts: 1112
Joined: 08 Dec 2005, 09:13
Location: Novy Bor, Czech Republic
Contact:

Post by Petr Solin »

zarevak wrote:Hi,
just a summary from Czech thread about similar topic Full linkovanie na NTFS - "Junction point":
- creating Junction Points
- viewing Junction Point links (to be able to see, where the link goes)
You can view target path of junction point when you enter it and use Drive Info (Ctrl+F1) command.
zarevak wrote:From another (Deleting a NTFS hardlink/junction) topic:
- plan to change Delete command to Unlink for Junction Points
I have just finished it, it will be available in next version (RC2).
User avatar
zarevak
Plugin Developer
Plugin Developer
Posts: 789
Joined: 04 Feb 2006, 16:49
Location: Prague, Czech Republic

Post by zarevak »

Petr Solin wrote:You can view target path of junction point when you enter it and use Drive Info (Ctrl+F1) command.
Petr Solin wrote:delete without recursive file remove - I have just finished it, it will be available in next version (RC2).
Thank you! Much appreciated ;)
User avatar
mdruiter
Posts: 262
Joined: 22 Feb 2006, 15:33
Location: Amsterdam, The Netherlands
Contact:

Hardlinks and Junctions

Post by mdruiter »

Petr Solin wrote:You can view target path of junction point when you enter it and use Drive Info (Ctrl+F1) command.
I understand the Enter, but what should Ctrl+F1 add to that? :?

Furthermore, is it by design that Ctrl+T ("Go to the target of the focused shortcut (.lnk file)") does not work on directory junctions, but only on files (also non-.lnk links)?
Last edited by mdruiter on 30 Oct 2009, 13:32, edited 2 times in total.
User avatar
mdruiter
Posts: 262
Joined: 22 Feb 2006, 15:33
Location: Amsterdam, The Netherlands
Contact:

Re: Hardlinks and Junctions

Post by mdruiter »

mdruiter wrote:I understand the Enter, but what should Ctrl+F1 add to that? :?
Wait, I understand it now: for junctions and directory symlinks, it shows the link (next to Local Disk)!
For junctions with denied read permission (such as "C:\Documents and Settings" in Vista), Salamander jumps to the target at Enter 8) (whereas Explorer just denies), so Drive Type cannot show the link source there.
Last edited by mdruiter on 02 Nov 2009, 13:06, edited 1 time in total.
Petr Solin
ALTAP Staff
ALTAP Staff
Posts: 1112
Joined: 08 Dec 2005, 09:13
Location: Novy Bor, Czech Republic
Contact:

Re: Hardlinks and Junctions

Post by Petr Solin »

I have junction point F:\test leading to C:\hudba. When I enter F:\test (path F:\test is in panel) and use Drive Info command (it has Ctrl+F1 hotkey), I can see "Drive type: Local Disk (junction to: C:\Hudba)" on the third row in Drive Information dialog.

Ctrl+T is only for .lnk files.
User avatar
zarevak
Plugin Developer
Plugin Developer
Posts: 789
Joined: 04 Feb 2006, 16:49
Location: Prague, Czech Republic

Re: Hardlinks and Junctions

Post by zarevak »

Hi, is there a way how to find the target location in Salamander without entering the folder? I had a junction point, which lead to some unavailable target and I didn't know where :(
Petr Solin
ALTAP Staff
ALTAP Staff
Posts: 1112
Joined: 08 Dec 2005, 09:13
Location: Novy Bor, Czech Republic
Contact:

Re: Hardlinks and Junctions

Post by Petr Solin »

zarevak wrote:Hi, is there a way how to find the target location in Salamander without entering the folder? I had a junction point, which lead to some unavailable target and I didn't know where :(
Probably no, sorry. If you can't find any command line utility for displaying junction points targets, I can send you source code of this rutine. ;-)
User avatar
zarevak
Plugin Developer
Plugin Developer
Posts: 789
Joined: 04 Feb 2006, 16:49
Location: Prague, Czech Republic

Re: Hardlinks and Junctions

Post by zarevak »

Petr Solin wrote:
zarevak wrote:Hi, is there a way how to find the target location in Salamander without entering the folder?
Probably no, sorry. If you can't find any command line utility for displaying junction points targets, I can send you source code of this rutine. ;-)
Thank you. It was just minor issue so I ignored it. It would be nice feature for Salamander though ;)
User avatar
mdruiter
Posts: 262
Joined: 22 Feb 2006, 15:33
Location: Amsterdam, The Netherlands
Contact:

Re: Hardlinks and Junctions

Post by mdruiter »

Petr Solin wrote:Ctrl+T is only for .lnk files.
I thought I saw it work for linked files too, but apparently not. :wink:
It would be useful if it also worked for linked files, to be able to see where it points to. One cannot "enter" it like a directory...
Petr Solin
ALTAP Staff
ALTAP Staff
Posts: 1112
Joined: 08 Dec 2005, 09:13
Location: Novy Bor, Czech Republic
Contact:

Re: Hardlinks and Junctions

Post by Petr Solin »

Maybe we should add support for reparse points (mount points, junctions, and symlinks) to Go to Shortcut Target command (Ctrl+T). :wink: It would also solve problem with inaccessible target directory (it could display some error message containing target path).
User avatar
Ether
Posts: 1471
Joined: 10 May 2007, 16:08
Location: Czech Republic
Contact:

Re: Hardlinks and Junctions

Post by Ether »

Petr Solin wrote:Maybe we should add support for reparse points (mount points, junctions, and symlinks) to Go to Shortcut Target command (Ctrl+T). :wink: It would also solve problem with inaccessible target directory (it could display some error message containing target path).
+1
Ελληνικά rulez.
User avatar
Georgd
Posts: 101
Joined: 24 Jul 2006, 17:13

Re:

Post by Georgd »

zarevak wrote:just a summary from Czech thread about similar topic Full linkovanie na NTFS - "Junction point":
- creating Junction Points
- viewing Junction Point links (to be able to see, where the link goes)
- editing Junction Points (to be able to change the link target)
Did anything happen on that front in the Czech forums?

CTRL+T - support for reparse points (mount points, junctions, and symlinks) as suggested by Petr Solin above is nice, but before I want to follow them I need to create & edit them ;) I care most about symlinks like stated in http://forum.altap.cz/viewtopic.php?f=3&t=3631&start=0 because they offer comfortable use of encrypted volumes for windows standard directories.
Using Salamander since v 1.52
Petr Solin
ALTAP Staff
ALTAP Staff
Posts: 1112
Joined: 08 Dec 2005, 09:13
Location: Novy Bor, Czech Republic
Contact:

Re: Hardlinks and Junctions

Post by Petr Solin »

I have just tried Manison's new plugin Automation. It adds command Make Link for creating symlinks. I believe other needed commands can be added too, supplied sample script just runs mklink utility.
Post Reply