in reply to How to create symlink using Perl?
Windows NTFS supports Junctions which are very similar to Unix symlinks (see also Sysinternals Junction).
Update: unlike Unix symlinks, be aware that Windows junctions are for directories only (see Re^5: How to create symlink using Perl? and Win32::Symlink for more detail).
I've successfully used the CPAN Win32::Symlink module by audreyt (in particular, it's symlink function) to write cross-platform code that used "symlinks" on both Unix and Windows. At the top of the program, I used:
BEGIN { if ($^O eq 'MSWin32') { require Win32::Symlink; Win32::Symlink->import(); } }
The rest of the code (using the symlink function) was the same for both platforms.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: How to create symlink using Perl?
by ikegami (Patriarch) on Oct 23, 2011 at 09:26 UTC | |
by reddevil (Initiate) on Oct 23, 2011 at 18:19 UTC | |
by Corion (Patriarch) on Oct 23, 2011 at 18:41 UTC | |
by reddevil (Initiate) on Oct 23, 2011 at 23:10 UTC | |
by eyepopslikeamosquito (Archbishop) on Oct 24, 2011 at 02:06 UTC | |
Re^2: How to create symlink using Perl?
by freonpsandoz (Beadle) on Oct 08, 2016 at 22:36 UTC |