Skip to content

Commit

Permalink
feat: update nvm and yarn to latest version (netlify#829)
Browse files Browse the repository at this point in the history
  • Loading branch information
danez authored Sep 30, 2022
1 parent c3bb703 commit f55c71a
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 11 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ USER root

RUN curl -o- -L https://yarnpkg.com/install.sh > /usr/local/bin/yarn-installer.sh

ENV NVM_VERSION=0.38.0
ENV NVM_VERSION=0.39.1

# Install node.js, yarn, grunt, bower and elm
USER buildbot
Expand All @@ -287,7 +287,7 @@ RUN git clone https://github.com/creationix/nvm.git ~/.nvm && \
cd /

ENV ELM_VERSION=0.19.1-5
ENV YARN_VERSION=1.22.10
ENV YARN_VERSION=1.22.19

ENV NETLIFY_NODE_VERSION="16"

Expand Down
2 changes: 1 addition & 1 deletion focal.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ commandTests:
echo "NPM: $(npm --version)"
expectedOutput:
- "Node: v16.*.*"
- "NVM: 0.38.0"
- "NVM: 0.39.1"
- "Yarn: 1.22.*"
- "NPM: 8.*.*"

Expand Down
2 changes: 1 addition & 1 deletion included_software.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ The specific patch versions included will depend on when the image was last buil

* Node.js
* Yarn - `YARN_VERSION`
* 1.22.10 (default)
* 1.22.19 (default)
* Any version available via their installer.
* NPM - `NPM_VERSION`
* Version corresponding with Node.js version. (default)
Expand Down
2 changes: 1 addition & 1 deletion run-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ cd $NETLIFY_REPO_DIR

: ${NODE_VERSION="16"}
: ${RUBY_VERSION="2.7.2"}
: ${YARN_VERSION="1.22.10"}
: ${YARN_VERSION="1.22.19"}
: ${GO_VERSION="1.17"}
: ${PYTHON_VERSION="3.8"}

Expand Down
7 changes: 1 addition & 6 deletions tests/node/yarn.bats
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ load '../../node_modules/bats-file/load'
YARN_CACHE_DIR=/opt/buildhome/.yarn_cache

# So that we can speed up the `run_yarn` function and not require new yarn installs for tests
YARN_DEFAULT_VERSION=1.22.10
YARN_DEFAULT_VERSION=1.22.19

setup() {
TMP_DIR=$(setup_tmp_dir)
Expand All @@ -27,11 +27,6 @@ teardown() {
cd - || return
}

@test 'yarn 1.22.10 is installed and available by default' {
run yarn --version
assert_output $YARN_DEFAULT_VERSION
}

@test 'run_yarn with a new yarn version correctly sets the new yarn binary in PATH' {
local newYarnVersion=1.21.0
# We can't use bats `run` because environmental changes aren't persisted
Expand Down

0 comments on commit f55c71a

Please sign in to comment.