<div dir="ltr"><br><br><br>On Thu, Oct 3, 2013 at 8:44 PM, Nikos Alexandris <<a href="mailto:nik@nikosalexandris.net">nik@nikosalexandris.net</a>> wrote:<br>><br>> Yann wrote:<br>><br>> > > The command was :<br>

> > > v.in.ascii -z input=${FILE} output=${NAME_OUT} separator="${FS}" z=3<br>> > > --overwrite<br>><br>> Hamish wrote:<br>><br>> > Hi,<br>><br>> > just to note -- the {curly} brackets do nothing to<br>

> > protect from spaces in filenames in this situation,<br>> > "double" quotes should be used for that.<br>> ><br>> > the curly brackets protect the variable name, not its<br>> > contents, so are mostly useful for when a letter,<br>

> > number, or "_" follows the variable name.<br>> ><br>> > I actually think it is dangerous to use the curly<br>> > brackets because it tricks people into thinking they<br>> > are protected when they are not.<br>

><br>> Maybe "${FILE}" then?  I remember this as being Glynn's recommendation, some<br>> time ago...<br>><br>Yes "${FILE}" should protect spaces and variable name.<br><br>$ MY_VARIABLE="GRASS is GIS"<br>

$ for A in $MY_VARIABLE; do echo $A; done;<div><div>GRASS</div><div>is</div><div>GIS</div><div>$ for A in "${MY_VARIABLE}"; do echo $A; done;<br>GRASS is GIS</div><div><br>But if I want to make thinks robust I use Python. Although module call itself is more complicated<br>

<br><div>input=file_name<br><br></div><div>is less complicated than</div><div><br></div><div>input="${FILE}"<br><br>Best,</div><div>Vaclav<br><br>><br>> Best, Nikos<br>><br>> _______________________________________________<br>

> grass-user mailing list<br>> <a href="mailto:grass-user@lists.osgeo.org">grass-user@lists.osgeo.org</a><br>> <a href="http://lists.osgeo.org/mailman/listinfo/grass-user">http://lists.osgeo.org/mailman/listinfo/grass-user</a><br>

</div></div></div></div>