Update setup-node-ubuntu.bash to use portable copy method as opposed to non-portable `tar --strip-components` in unpacking step.
This commit is contained in:
parent
31b92cdadb
commit
6c0afe6488
|
@ -59,7 +59,10 @@ if [ -n "${NODEJS_VER}" ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
mkdir -p ${NODEJS_UNTAR}/
|
mkdir -p ${NODEJS_UNTAR}/
|
||||||
tar xf ${NODEJS_LOCAL} -C ${NODEJS_UNTAR}/ --strip-components=1
|
# --strip-components isn't portable, switch to portable version by performing move step after untar
|
||||||
|
tar xf ${NODEJS_LOCAL} -C ${NODEJS_UNTAR}/ #--strip-components=1
|
||||||
|
mv ${NODEJS_UNTAR}/${NODEJS_NAME}-${NODEJS_VER}-linux-${ARCH}/* ${NODEJS_UNTAR}/
|
||||||
|
rm -rf ${NODEJS_UNTAR}/${NODEJS_NAME}-${NODEJS_VER}-linux-${ARCH} # clean up the temporary unzip folder
|
||||||
rm ${NODEJS_UNTAR}/{LICENSE,CHANGELOG.md,README.md}
|
rm ${NODEJS_UNTAR}/{LICENSE,CHANGELOG.md,README.md}
|
||||||
sudo rsync -a "${NODEJS_UNTAR}/" "$node_install_path/"
|
sudo rsync -a "${NODEJS_UNTAR}/" "$node_install_path/"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue