Skip to content

Commit 423b8f6

Browse files
authored
codeintel: add ignore-engines based on yarn version (#197)
1 parent e17a427 commit 423b8f6

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

dev/lenient-yarn.sh

+7-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,13 @@
11
#!/usr/bin/env bash
22
set -eux
33

4+
ADDITIONAL_ARGS="--ignore-engines"
5+
if [ "$(/usr/local/bin/actual-yarn --version | cut -d'.' -f1)" -gt 1 ]; then
6+
ADDITIONAL_ARGS=""
7+
fi
8+
49
if [ $# -gt 1 ] && [ "$1" == "install" ]; then
5-
/usr/local/bin/actual-yarn "$@" || echo "scip-typescript: ignoring yarn install failure, will try to auto-index the project with partial dependency information"
10+
/usr/local/bin/actual-yarn $ADDITIONAL_ARGS "$@" || echo "scip-typescript: ignoring yarn install failure, will try to auto-index the project with partial dependency information"
611
else
7-
/usr/local/bin/actual-yarn "$@"
12+
/usr/local/bin/actual-yarn $ADDITIONAL_ARGS "$@"
813
fi

0 commit comments

Comments
 (0)