how is it possible to run these two commands and then truncate them to the end of the curly bracket? thanks
a=g; z="abcdefgh"
echo ${z%%$a*}
error:
echo ${z%%$a:0:4}
echo ${z//ab/01}
error:
echo ${${z//ab/01}:0:4}
how is it possible to run these two commands and then truncate them to the end of the curly bracket? thanks
a=g; z="abcdefgh"
echo ${z%%$a*}
error:
echo ${z%%$a:0:4}
echo ${z//ab/01}
error:
echo ${${z//ab/01}:0:4}