I'm trying to read a file which holds a single number in ash shell. The bash way of doing so
ARG=`cat /tmp/tempfile`
doesn't work and I get that ARG doesn't hold anything after this line of code.
try to surround it with quotes to have it not stopped at the first newline:
ARG="`cat /tmp/tempfile`"
or
ARG="$(cat /tmp/tempfile)"
or
read ARG </tmp/tempfile #only 1st line will be read