Questions tagged [symlink-traversal]
46 questions
2
votes
3 answers
"tracing" version of readlink(1)
I would like a version of "readlink -f" that provides a trace of every individual symlink resolution it performs. Something like:
$ linktrace /usr/lib64/sendmail
/usr/lib64 -> lib
/usr/lib/sendmail -> ../sbin/sendmail
/usr/sbin/sendmail
$
I know…
jonrock
- 119
- 2
- 6
2
votes
0 answers
Eclipse CDT indexer won't follow symlinks?
In my source folders, I have two alternate versions of some part of my code, with a symlink choosing which one will be built. Now, in Eclipse, I use a resource filter to not see the two originals and only be able to see the symlink. However, for…
einpoklum
- 86,754
- 39
- 223
- 453
2
votes
1 answer
Are there any problems with this symlink traversal code for Windows?
In my efforts to resolve Python issue 1578269, I've been working on trying to resolve the target of a symlink in a robust way. I started by using GetFinalPathNameByHandle as recommended here on stackoverflow and by Microsoft, but it turns out that…
Jason R. Coombs
- 36,798
- 8
- 75
- 83
2
votes
1 answer
Why can't Safari connect to localhost?
I have a proper /etc/hosts file with the following contents:
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
fe80::1%lo0 localhost
When I try to access a server I have running on my local computer, whether it is…
Terry Roe
- 1,124
- 10
- 15
1
vote
1 answer
Resolving symlinks in lua
I tried googling, but I found only additional packages handling this (which I would like to avoid for various reasons).
In Lua5.3, is there some way to resolve a symlink, possibly recursively, using just the standard library?
I'm looking for…
ZioByte
- 1,822
- 21
- 44
1
vote
1 answer
How do I checkout then copy to all files at the destination of a symlink at once?
Background
I am following some instructions from a teammate. These instructions include a command to checkout, then copy .a files from a make command from one vob to another. The commands were given to me as such:
ct co -nc -unr…
isakbob
- 1,150
- 1
- 9
- 31
1
vote
1 answer
Is there a way to determine the destination path of a symlink in node?
Situation
I just ran into an odd situation that should not happen often, but I would like to prevent it from ever happening again.
I have a chunk of code that creates a deep dive directory list of all the files in a source folder and all of its…
Intervalia
- 8,536
- 1
- 21
- 47
1
vote
2 answers
Backing up symlinks using AWS s3 sync
I'm attempting to backup our system using the aws s3 sync command, however this will either backup the entire directory behind a symlink (default behaviour), or not backup the symlink at all.
I'd like some way of backing up the symlink so it can be…
TobyG
- 1,452
- 3
- 18
- 34
1
vote
0 answers
Symlink/link in project directory
I've got a project directory that's become a bit of a mess, and I'm trying to tidy it up into a structure something like this:
/data
/raw
/cleaning_scripts
/analysis
...
Some of the raw data is kept in a directory outside the project…
Empiromancer
- 3,258
- 1
- 15
- 41
1
vote
1 answer
Do CMake's find_ commands traverse symlinks?
I'm writing a Find.cmake module, because no good one exists for the library in question. This necessitates usage of the find_path and find_library commands. I'm testing it on macOS El Capitan.
Through means that are not relevant to this…
JesseTG
- 1,723
- 1
- 19
- 40
1
vote
2 answers
Is there a way in PHP to check if a directory is a symlink?
I have symlinks to certain directories because the directories' names have non English characters that I got fed up trying to get apache's rewrite rules to match. There's a bounty on that question trouble with utf-8 chars & apache2 rewrite rules…
Colleen Kitchen
- 1,049
- 1
- 11
- 20
1
vote
2 answers
Efficient way to walk directory tree containing link cycles
Is there a more efficient way to walk a directory tree that contains link cycles than tracking which files have already been visited?
For example consider walking a directory containing these files:
symlink "parent" -> ".."
symlink "uh_oh" ->…
Matt Joiner
- 100,604
- 94
- 332
- 495
1
vote
1 answer
How to determine if a linux symbolic link points to a directory or a file
I have a directory that has symbolic links - some of them point to files and some of them to directories - how do I identify the ones poiting to directory in a shell script ( without any prejudice to names offcourse)
Yogesh Devi
- 437
- 5
- 22
1
vote
0 answers
How to use symlinks with PHP and Nginx (or Lighttpd)?
I've installed Nginx + FPM-PHP under Debian and ArchLinux. Both are working fine. However, I can't figure out how to get the PHP part to follow symlinks. I've also tried with Lighttpd, but to no avail.
Here is what I want to do:
Root directory…
Luis Soeiro
- 4,162
- 5
- 33
- 45
1
vote
2 answers
Resolving all symbolic links in NSURL
I'm writing a little piece of code in which I should detect if an NSURL contains a symbolic link (i.e., symbolic file components other than the last one should also be detected). To do this, I confront the NSURL itself with the NSURL returned by…
Nickkk
- 1,891
- 1
- 20
- 31