Quote:
Originally Posted by nhedgehog
No it wasn't, but testing this on another unrooted device with a more recent FW tells me, that neither:
cp /mnt/secure/device.cfg /mnt/ext1
nor
/var/run/device.cfg >> /mnt/ext1/device.cfg
is working! (permission denied)
PS @neil_swann80: Thanks for your contributions to the community, it is really appreciated.
|
Did you definitely test:
echo /var/run/device.cfg >> /mnt/ext1/device.cfg
EDIT: that would just write the filepath to the new file!

The actual script copies the file from /var/run to the user area, then reads it with the cat command.
So a better test would be:
cp /var/run/device.cfg /mnt/ext1/device.cfg
or better still:
Code:
echo have_opds=1 > /mnt/ext1/device.cfg
IFS=''; cat "/var/run/device.cfg" |
while read data; do
if echo "$data" | grep -q "have_opds"; then :
else echo "${data}" >> "/mnt/ext1/device.cfg"; fi
done