help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-bash] Completing file names with spaces in them.


From: Eduardo Bustamante
Subject: Re: [Help-bash] Completing file names with spaces in them.
Date: Sat, 31 Dec 2016 01:06:31 -0600

Your code lacks proper coding. I recommend reading:
http://mywiki.wooledge.org/Quotes
http://mywiki.wooledge.org/BashGuide/Arrays
http://mywiki.wooledge.org/ParsingLs

In short, doing:

  array=($(...))

will destroy word boundaries. That's not the way to do it. And make
sure you quote every parameter expansion:

  ${cur}   -> "${cur}"
  $1       ->  "$1"



reply via email to

[Prev in Thread] Current Thread [Next in Thread]