You are not logged in.
I've been hacking on GNU/Linux for a long time, so obviously I'm familiar with ./ and use it often. It seems that ././ is also sometimes used to mean "here" (for example, see the No hard-coded paths section here).
Have you ever encountered ././ before? I have only ever seen it in the AppImage guide in the link above. Please, what's the difference between ./ and ././? Internet searches have not turned up anything even remotely relevant this question.
Last edited by GNUser (2018-05-30 19:20:12)
Offline
I have often used something similar ../ or even .../ in web design to navigate to various files in the tree structure of a complicated site. Is ././ in a path to a file? Or within some code?
Offline
Yes, ././ in the context of AppImage creation are the leading characters in a relative path and means "here". I can confirm that it works:
bruno@thinkpad:~$ cd /bin
bruno@thinkpad:/bin$ ././echo test
test
bruno@thinkpad:/bin$
But for the life of me I can't figure out why someone wouldn't simply use plain ol' ./. Maybe the AppImage guys are unaware that the simpler form is equivalent? Maybe ././ also works in other OSes but ./ only works in GNU/Linux? I'm at a loss.
If none of my Devuan friends know, I may contact the AppImage guys to ask them.
Last edited by GNUser (2018-05-30 18:47:57)
Offline
I asked the AppImage guys and they explained it to me: https://github.com/AppImage/AppImageKit … -393284213
In a word, ././ is redundant. It's a hack to convert absolute paths (e.g., /usr/bin/foo) to relative paths (e.g., ././/bin/foo) without changing the length of the string. Binaries have internal addresses, so if the length of a string inside a binary is changed when patching the binary to make it portable, the binary will no longer work because things will no longer be at the expected addresses.
Last edited by GNUser (2018-05-31 18:29:39)
Offline
It's not at all obvious to me . . .
Offline