Skip to content

Commit

Permalink
Update StartDB1000N.bat (#507)
Browse files Browse the repository at this point in the history
* Update StartDB1000N.bat

Add -UseBasicParsing in Invoke-WebRequest to avoid this error message :

"The response content cannot be parsed because the Internet Explorer engine is not available, or Internet Explorer's first-launch configuration is not complete. Specify the UseBasicParsing parameter and try again."

* Update StartDB1000N.bat
  • Loading branch information
nicolaspbl authored Apr 15, 2022
1 parent 79918b7 commit 93c189e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/StartDB1000N.bat
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@ rem Create target folder if it don't exist yet
echo New-Item -ItemType Directory -Force -Path $SaveFolder >> %temp%\GetDB1000N.ps1
rem Getting list of files in latest release via github API and parse response JSON
echo $JSONURL = "https://api.github.com/repos/Arriven/db1000n/releases/latest" >> %temp%\GetDB1000N.ps1
echo $JSON = Invoke-WebRequest -Uri $JSONURL >> %temp%\GetDB1000N.ps1
echo $JSON = Invoke-WebRequest -Uri $JSONURL -UseBasicParsing >> %temp%\GetDB1000N.ps1
echo $ParsedJSON = ConvertFrom-Json -InputObject $JSON >> %temp%\GetDB1000N.ps1
echo $Assets = Select-Object -InputObject $ParsedJSON -ExpandProperty assets >> %temp%\GetDB1000N.ps1
rem Iterate over list of all files in release
echo Foreach ($Asset IN $Assets) >> %temp%\GetDB1000N.ps1
echo { >> %temp%\GetDB1000N.ps1
rem Search for windows x64 build with regex
echo if ($Asset.name -match 'db1000n_windows_amd64.zip') >> %temp%\GetDB1000N.ps1
echo { >> %temp%\GetDB1000N.ps1
echo if ($Asset.name -match 'db1000n_windows_amd64.zip') >> %temp%\GetDB1000N.ps1
echo { >> %temp%\GetDB1000N.ps1
rem Download found build
echo $DownloadURL = $Asset.browser_download_url >> %temp%\GetDB1000N.ps1
echo $ZIPPath = Join-Path -Path $SaveFolder -ChildPath "db1000n.zip" >> %temp%\GetDB1000N.ps1
Expand Down

0 comments on commit 93c189e

Please sign in to comment.