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

do_dchroot



Current do_dchroot script in howto doesn't work with ' in parameters.
This is what I use:

#!/bin/bash

for (( i=1; $i<=$#; i=$i+1 )); do
  esc[$i]=$(sed -e 's#\([^[:alnum:]]\)#\\\1#g' <<<${!i})
done

exec dchroot -c ia32 -d "$(basename $0)" "${esc[@]}"

maybe it escapes little to much, but it works.

-- 
 Me



Reply to: