recentpopularlog in

kme : symlinks   14

Reliable way for a bash script to get the full path to itself? - Stack Overflow - http://stackoverflow.com/
You can shorten this further. Both backticks and $( ) run their eval in a subshell, so there's no reason to surround this with pushd/popd pairs. Instead:

SCRIPTPATH=$( cd $(dirname $0) ; pwd -P )

– sfstewman Jul 15 '12 at 21:15
bash  shellscripting  symlinks  pathname  solution  library  essential 
march 2016 by kme
upload - Best practice to link with WebDAV, as FollowSymLinks doesn’t allow to show symlinks - Server Fault - http://serverfault.com/
However, there are good reasons to work with WebDAV instead, port issues are one of them. The problem when porting such an application to WebDAV: Apache’s mod_dav is written in a way symbolic links are not exposed, no matter wether FollowSymLinks is set. This behaviour is intended by the communtiy, therefore a bug report was never tackled


See also: http://www.webdav.org/mod_dav/faq/#04-02

Interestingly:
Last, a symlink patch for mod_dav-1.0.3-1.3.6 has been published, but you will have to apply the patch onto the source code and compile the module yourself … I didn’t try that.
apache  webdav  annoyance  symlinks  webmaster 
january 2016 by kme
symlink - How do I copy symbolic links in Perl? - Stack Overflow
Assuming sufficient permissions (nb: unchecked code)

use Lchown;
my $old_link = 'path to the symlink';
my $new_link = 'path to the copy';

my $dst = readlink($old_link);
my @stat = lstat($old_link);

symlink $dst, $new_link;
lchown $stat[4], $stat[5], $new_link; # set UID and GID from the lstat() results
perl  symlinks  solution 
november 2015 by kme

Copy this bookmark:





to read