File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,6 @@ COPY scripts/nodejs.sh /scripts/
2828RUN sh /scripts/nodejs.sh /node
2929ENV PATH="/node/bin:${PATH}"
3030
31- # Install eslint
3231COPY host-x86_64/tidy/eslint.version /tmp/
3332
3433COPY scripts/sccache.sh /scripts/
@@ -40,7 +39,8 @@ RUN pip3 install --no-deps --no-cache-dir --require-hashes -r /tmp/reuse-require
4039
4140COPY host-x86_64/pr-check-1/validate-toolstate.sh /scripts/
4241
43- RUN bash -c 'npm install -g eslint@$(cat /tmp/eslint.version)'
42+ # Install eslint
43+ RUN bash -c 'yarn global add eslint@$(cat /tmp/eslint.version)'
4444
4545# NOTE: intentionally uses python2 for x.py so we can test it still works.
4646# validate-toolstate only runs in our CI, so it's ok for it to only support python3.
Original file line number Diff line number Diff line change 33set -ex
44
55NODEJS_VERSION=v20.12.2
6+ YARN_VERSION=1.22.22
67INSTALL_PATH=${1:-/ node}
78
89url=" https://nodejs.org/dist/${NODEJS_VERSION} /node-${NODEJS_VERSION} -linux-x64.tar.xz"
910curl -sL " $url " | tar -xJ
1011mv node-${NODEJS_VERSION} -linux-x64 " ${INSTALL_PATH} "
12+
13+ # now, install yarn.
14+ # we call npm through the node binary, because otherwise npm will expect node to be in the PATH
15+ " ${INSTALL_PATH} /bin/node" " ${INSTALL_PATH} /bin/npm" install --global yarn@${YARN_VERSION}
You can’t perform that action at this time.
0 commit comments