csv as argument

Jorge Almeida jalmeida
Thu Jul 19 09:24:44 PDT 2007


This is probably a stupid question, but anyway. Is there some way to
coax bash into accepting a csv string as argument? Like this:
 	myprogram "aaa","   gg","aa,b","a""n"

All this stuff should constitute a single argument. The idea is that the
program itself would do the parsing.
The shell removes the quotes. Enclosing the whole string in single
quotes would do the work, but then what if the string itself has single
quotes?

Any idea? Or is this the wrong problem by all accounts?

-- 
Jorge Almeida



More information about the Linux-users mailing list