Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

"splitting prpblem"



HI,

 I have a kind of "splitting problem" -- and dont know how to
 categorize or name it...

 This is it:
 I made a script to repack all my *.tar.bz2 files into *.7z file with
 the high compression packer p7zip.

 P7zip supports a couple of optimizing options to get most of it in
 dependance of the used machine (mem etc...).

 To not to repeat these options every time on a line where p7zip is
 called I put them into a variable:

		opt="-t7z -m0=lzma -mx=8 -mfb=64"

 Now...
 When calling p7zip with

	  7z a $opt <file> <arc.7z>

 p7zip gets confused, because it sees the parameters in $opt as one
 monlithic block of text.

 Is there a way to say: "Hey zsh,...if you expand this variable,
 please let it look like single options..." ?

 I dont want to call big brothers of big sisters of the utils family
 like sed, ed, cut, grep or whatever for this tiny job...

 (...and for what keyword I had to search for in th ezshall docs...I
 tried things like "$1", "variable expansion", "split" and such and
 found nothing appropiate...)

 Keep zshing!
 Meino



Messages sorted by: Reverse Date, Date, Thread, Author