Date: Thu, 6 Feb 2020 17:55:13 +0100 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= <rank1seeker@gmail.com> To: hackers@freebsd.org Subject: [t]csh => Pass var containing multiline string to an alias Message-ID: <20200206175513.00006006@gmail.com>
next in thread | raw e-mail | index | archive | help
Yo Crew ..., so ... I want to pass variable containing multiline string to an alias, so it woul= d also be multiline string. Var first: -- set t_var=3D'a\ b' -- Expands to: -- a b -- So far so good, now alias: Double quotes are mandatory, else all ends up at 1 line -- alias t_name "aa $t_var bb" -- Error: Unmatched '"'. Manual replacement: -- alias t_name "aa a\ b bb" -- Results in: # alias t_name aa a b bb Exactly what I want ... Going back to var in order to make it, to be expanded with additional \ -- set t_var=3D'a\\ b' -- Expands to: -- a\ b -- And that is exactly a string which I've manually replaced above. After # source /.cshrc Unmatched '"'. What is going on? I've tried adding many \'s and playing wit all types of quotes in all kind = of combinations just to find out I've lost 4 hours on something like THIS! Am I completely missing something totally obvious?!? PS: version tcsh 6.20.00 (Astron) 2016-11-24 (i386-intel-FreeBSD) options w= ide,nls,dl,al,kan,sm,rh,color,filec Domagoj Smol=C4=8Di=C4=87
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20200206175513.00006006>