configure: test for yarn help result containing "No such file" etc,
so that we can catch the yarn possibly installed by cmdtest. This can lead to issues, and I don't understand why apt and maybe other PMs allow namespace collisions, or resolve them in a way which allows this to happen.
This commit is contained in:
parent
6e138efee0
commit
040475967c
12
configure
vendored
12
configure
vendored
@ -83,11 +83,23 @@ else
|
|||||||
#echo "Using node ${node_version}"
|
#echo "Using node ${node_version}"
|
||||||
if ! node -p 'process.exit(!(/v([0-9]+)/.exec(process.version)[1] >= 4))'; then
|
if ! node -p 'process.exit(!(/v([0-9]+)/.exec(process.version)[1] >= 4))'; then
|
||||||
echo 'Your node version is too old, use Node 4.x or newer'
|
echo 'Your node version is too old, use Node 4.x or newer'
|
||||||
|
exit 1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! existence yarn; then
|
if ! existence yarn; then
|
||||||
echo 'ERROR: yarn missing. See https://yarnpkg.com/en/docs/install'
|
echo 'ERROR: yarn missing. See https://yarnpkg.com/en/docs/install'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if existence cmdtest; then
|
||||||
|
if yarn help | grep "No such file or directory"; then
|
||||||
|
echo "ERROR: wrong yarn binary installed, please remove the"
|
||||||
|
echo "ERROR: conflicting binary before continuing."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
echo "WARNING: cmdtest is installed, this can lead to known issues"
|
||||||
|
echo "WARNING: with yarn."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# for the weird systems and sandboxes, only as a anotice.
|
# for the weird systems and sandboxes, only as a anotice.
|
||||||
|
Loading…
Reference in New Issue
Block a user