[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

bash: a pipe bodge, is there a better way ?

I have a pipe of commands ....

echo $scanhtml | csplit -f index -q - /lock/ {*}

I want the output to go to $tempdir/websync/ ... Is there a more elegant way than my present solution of ..

cd $tempdir/websync
echo $scanhtml | csplit -f index -q - /lock/ {*}

This seems a bit of a bodge and I am sure there is a better way..


PS I used echo $scanhtml | because to use this directly in csplit seletes the file if a split is done !

Reply to: