Skip to content

Commit

Permalink
Use circleci/windows orb to get VS preinstalled
Browse files Browse the repository at this point in the history
Summary:
We currently use a standard Windows image and then install Visual Studio on it. This setup takes ~15 minutes.

This diff instead uses a Windows image where Visual Studio is preinstalled.

Reviewed By: neildhar

Differential Revision: D22579509

fbshipit-source-id: 0a735946b9aade3d02c11361a6b785971efbb8d1
  • Loading branch information
willholen authored and facebook-github-bot committed Jul 17, 2020
1 parent faa5c24 commit c7b490c
Showing 1 changed file with 2 additions and 23 deletions.
25 changes: 2 additions & 23 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ version: 2.1
# Comments saying "see top comment" refer to this.

orbs:
win: circleci/windows[email protected]
win: circleci/windows@2.4.0

workflows:
version: 2
Expand Down Expand Up @@ -323,7 +323,7 @@ jobs:
windows:
executor:
name: win/preview-default
name: win/default
shell: powershell.exe
environment:
- HERMES_WS_DIR: 'C:\tmp\hermes'
Expand Down Expand Up @@ -360,27 +360,6 @@ jobs:
choco install --no-progress python3
if (-not $?) { throw "Failed to install Python" }
# dotnetfx-4.8.0 requires a reboot, so pin an earlier version
choco install --no-progress dotnetfx --version 4.7.2.20180712
if (-not $?) { throw "Failed to install dotnetfx" }
# Choco installs of VS2019 are so slow that CircleCI times it out
# after 10 minutes of perceived inactivity. There's no verbose flag,
# so we'll just print something occasionally to bump the timer.
$install = Start-Job {
choco install visualstudio2019buildtools --package-parameters "--allWorkloads --includeRecommended --passive --locale en-US"
}
$eta = 15
while ($install.State -eq "Running") {
Write-Host "Waiting for visualstudio2019buildtools. ETA $eta minutes..."
$install | Wait-Job -timeout 60
$eta -= 1
}
$install | Receive-Job
if (-not $?) { throw "Failed to install visualstudio2019buildtools" }
choco install visualstudio2019-workload-vctools
if (-not $?) { throw "Failed to install visualstudio2019-workload-vctools" }
- run:
name: Assemble Windows runtime dependencies
command: |
Expand Down

0 comments on commit c7b490c

Please sign in to comment.