Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Variable expansion problem
- X-seq: zsh-users 11876
- From: "John Cooper" <john.cooper@xxxxxxxxxxxxx>
- To: <zsh-users@xxxxxxxxxx>
- Subject: Variable expansion problem
- Date: Tue, 25 Sep 2007 08:39:38 +0100
- Cc: "John Cooper" <john.cooper@xxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- Thread-index: Acf/RzDUDevsODQVSd2r3NgR/Q0rFA==
- Thread-topic: Variable expansion problem
I'd like to have a mechanism such that I can type $FOO<TAB> and have it expand to the following which I can then manually edit further:
"C:\Program Files (x86)\Citrix\Web Interface\5.0.0\sitemgr.exe" -c "WIDest=1:/Citrix/AccessPlatform,Config=Local,XMLService=beanstalk:80"
I've tried:
PF="C:\Program Files (x86)"
FOO="$PF\Citrix\Web Interface\5.0.0\sitemgr.exe -c \"WIDest=1:/Citrix/AccessPlatform,Config=Local,XMLService=beanstalk:80\""
.. but this expands the value into a single escaped string:
$ C:\\Program\ Files\ \(x86\)\\Citrix\\Web\ Interface\\5.0.0\\sitemgr.exe\ -c\ \"WIDest=1:/Citrix/AccessPlatform,Config=Local,XMLService=beanstalk:80\"
If I try `setopt shwordsplit' (which I don't really want), the spaces in the expanded path are no longer quoted causing the cmd to fail:
C:\\Program Files \(x86\)\\Citrix\\Web Interface\\5.0.0\\sitemgr.exe -c \"WIDest=1:/Citrix/AccessPlatform,Config=Local,XMLService=beanstalk:80\"
zsh: command not found: C:\Program
I also don't want the double-quotes to be quoted in the expansion.
Any ideas how to do this?
Thanks,
--- John
Messages sorted by:
Reverse Date,
Date,
Thread,
Author