Skip to content

Commit

Permalink
Merge pull request #2623 from snyk/chore/windows-nodejs-choco
Browse files Browse the repository at this point in the history
chore(ci): move windows nodejs to choco config
  • Loading branch information
Jahed Ahmed committed Jan 25, 2022
2 parents f2764b1 + 749429f commit 8aa6f60
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 15 deletions.
1 change: 1 addition & 0 deletions .circleci/chocolatey.config
Expand Up @@ -4,4 +4,5 @@
<package id="gradle" version="6.8.3" />
<package id="sbt" version="1.5.5" />
<package id="awscli" version="2.4.12" />
<package id="nodejs" version="16.13.2" />
</packages>
20 changes: 5 additions & 15 deletions .circleci/config.yml
Expand Up @@ -71,6 +71,11 @@ commands:
- << parameters.npm_cache_directory >>
install_sdks_windows:
steps:
- run:
name: Removing pre-installed NodeJS
command: |
$current_node_version = node --version
nvm uninstall $current_node_version
- restore_cache:
name: Restoring Chocolatey cache
keys:
Expand Down Expand Up @@ -119,19 +124,6 @@ commands:
key: sdkman-archive-cache-v3-{{ arch }}-{{ checksum ".circleci/install-sdks-linux.sh" }}
paths:
- ~/.sdkman/archives
install_node_windows:
parameters:
node_version:
type: string
steps:
- run:
name: Removing pre-installed NodeJS
command: |
$current_node_version = node --version
nvm uninstall $current_node_version
- run:
name: Installing NodeJS
command: choco install nodejs --version=<< parameters.node_version >> --no-progress
install_shellspec_dependencies:
steps:
- run:
Expand Down Expand Up @@ -248,8 +240,6 @@ jobs:
- checkout
- attach_workspace:
at: .
- install_node_windows:
node_version: << parameters.node_version >>
- install_sdks_windows
- setup_npm:
node_version: << parameters.node_version >>
Expand Down

0 comments on commit 8aa6f60

Please sign in to comment.