Andreas Schwab <schwab@suse.de> writes:
> Padraig@linux.ie (Padraig Brady) writes:
>|> ?
>|> newpath=`echo $PATH | tr : '\n' | uniq | tr '\n' :`
>
> uniq only works on sorted input (it only compares successive lines).
sort -u (or sort|uniq) could be used instead. But this will still
fail if any of the entries happens to contain a newline, and it
requires that you have these external commands installed. Not that
these are major obstacles.
paul