summaryrefslogtreecommitdiff
path: root/scripts/bk_tests/bk_win_prep.ps1
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/bk_tests/bk_win_prep.ps1')
-rw-r--r--scripts/bk_tests/bk_win_prep.ps120
1 files changed, 20 insertions, 0 deletions
diff --git a/scripts/bk_tests/bk_win_prep.ps1 b/scripts/bk_tests/bk_win_prep.ps1
new file mode 100644
index 0000000000..1d7199916b
--- /dev/null
+++ b/scripts/bk_tests/bk_win_prep.ps1
@@ -0,0 +1,20 @@
+echo "--- system details"
+$Properties = 'Caption', 'CSName', 'Version', 'BuildType', 'OSArchitecture'
+Get-CimInstance Win32_OperatingSystem | Select-Object $Properties | Format-Table -AutoSize
+
+echo "--- update bundler"
+
+ruby -v
+if (-not $?) { throw "Can't run Ruby. Is it installed?" }
+
+$env:BUNDLER_VERSION=$(findstr bundler omnibus_overrides.rb | %{ $_.split(" ")[3] })
+$env:BUNDLER_VERSION=($env:BUNDLER_VERSION -replace '"', "")
+echo $env:BUNDLER_VERSION
+
+gem install bundler -v $env:BUNDLER_VERSION --force --no-document --quiet
+if (-not $?) { throw "Unable to update Bundler" }
+bundle --version
+
+echo "--- bundle install"
+bundle install --jobs=3 --retry=3 --without omnibus_package docgen chefstyle
+if (-not $?) { throw "Unable to install gem dependencies" }