create tmpdir via mktemp
replace /tmp/Extensions with "${tmpdir}"