mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-20 06:29:50 +00:00
add creation of directories
This commit is contained in:
@@ -20,11 +20,21 @@ Remove-Item $DriversZipFile;
|
|||||||
|
|
||||||
$SeleniumWebDriverPath = Join-Path $DestinationPath "SeleniumWebDrivers"
|
$SeleniumWebDriverPath = Join-Path $DestinationPath "SeleniumWebDrivers"
|
||||||
$IEDriverPathTemp = Join-Path $TempSeleniumDir 'IEDriver'
|
$IEDriverPathTemp = Join-Path $TempSeleniumDir 'IEDriver'
|
||||||
|
|
||||||
|
if (-not (Test-Path -Path $SeleniumWebDriverPath)) {
|
||||||
|
New-Item -Path $SeleniumWebDriverPath -ItemType "directory"
|
||||||
|
}
|
||||||
|
|
||||||
Move-Item -Path "$IEDriverPathTemp" -Destination $SeleniumWebDriverPath
|
Move-Item -Path "$IEDriverPathTemp" -Destination $SeleniumWebDriverPath
|
||||||
|
|
||||||
|
|
||||||
# Reinstall Chrome Web Driver
|
# Reinstall Chrome Web Driver
|
||||||
$ChromeDriverPath = "${DestinationPath}SeleniumWebDrivers\ChromeDriver";
|
$ChromeDriverPath = "${DestinationPath}SeleniumWebDrivers\ChromeDriver";
|
||||||
|
|
||||||
|
if (-not (Test-Path -Path $ChromeDriverPath)) {
|
||||||
|
New-Item -Path $ChromeDriverPath -ItemType "directory"
|
||||||
|
}
|
||||||
|
|
||||||
$RegistryPath = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths"
|
$RegistryPath = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths"
|
||||||
$ChromePath = (Get-ItemProperty "$RegistryPath\chrome.exe").'(default)';
|
$ChromePath = (Get-ItemProperty "$RegistryPath\chrome.exe").'(default)';
|
||||||
[version]$ChromeVersion = [System.Diagnostics.FileVersionInfo]::GetVersionInfo($ChromePath).ProductVersion;
|
[version]$ChromeVersion = [System.Diagnostics.FileVersionInfo]::GetVersionInfo($ChromePath).ProductVersion;
|
||||||
|
|||||||
Reference in New Issue
Block a user