[Bash-completion-devel] [bash-completion-Bugs][313659] 'readlink -f' is not portable

bash-completion-bugs at alioth.debian.org bash-completion-bugs at alioth.debian.org
Wed May 30 21:01:44 UTC 2012


bash-completion-Bugs item #313659, was changed at 2012-05-31 00:01 by Ville Skyttä
You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=313659&group_id=100114

Status: Open
Priority: 3
Submitted By: Nobody (None)
Assigned to: Nobody (None)
Summary: 'readlink -f' is not portable 
Distribution: --Distribution-Agnostic--
Originally reported in: None
Milestone: None
Status: None
Original bug number: 


Initial Comment:
Anonymous message posted by jacknagel at gmail.com

The _realcommand() function in the bash_completion script sniffs for readlink(1) and then uses 'readlink -f' to resolve symlinks. However, this is not portable; the readlink shipping with at least Mac OS X (and I would imagine some of BSDs) does not have the '-f' option. AFAIK it isn't possible to use this readlink to resolve multiple levels of symlinks.

----------------------------------------------------------------------

>Comment By: Ville Skyttä  (scop-guest)
Date: 2012-05-31 00:01

Message:
Not a complete fix for the problem, but greadlink might save the day in some cases.
http://anonscm.debian.org/gitweb/?p=bash-completion/bash-completion.git;a=commitdiff;h=32f223963a013e4875c999109c0a2fa8f9a0ecdf

----------------------------------------------------------------------

You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=313659&group_id=100114



More information about the Bash-completion-devel mailing list