This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$logLocation = "%userprofile%\AppData\LocalLow\miHoYo\Genshin Impact\output_log.txt"; | |
$path = [System.Environment]::ExpandEnvironmentVariables($logLocation); | |
if (-Not [System.IO.File]::Exists($path)) { | |
Write-Host "Cannot find the log file! Make sure to open the wish history first!" -ForegroundColor Red | |
exit | |
} | |
$logs = Get-Content -Path $path | |
$match = $logs -match "^OnGetWebViewPageFinish.*log$" | |
if (-Not $match) { | |
Write-Host "Cannot find the wish history url! Make sure to open the wish history first!" -ForegroundColor Red |