babu_says
08-06-2003, 05:33 AM
Hi,
I tried the following
[...]$ var1="xyz/abc"
[...]$ echo ${var1%abc}
xyz/
[...]$ echo ${var1%/abc}
xyz
[...]$ echo ${var1%*/}
xyz/abc
I expected a "xyz" for the last statement. Could somebody help me get the last one right?
TIA,
Babu
I tried the following
[...]$ var1="xyz/abc"
[...]$ echo ${var1%abc}
xyz/
[...]$ echo ${var1%/abc}
xyz
[...]$ echo ${var1%*/}
xyz/abc
I expected a "xyz" for the last statement. Could somebody help me get the last one right?
TIA,
Babu