# >>> Cursor UTF-8 config >>>
# %USER_PROFILE%\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1
if ($env:CURSOR_AGENT -eq '1' -and $true) {
try {
chcp 65001
$env:PYTHONUTF8=1
Write-Host "Cursor: Set encoding to UTF-8 success" -ForegroundColor Green
} catch {
Write-Host "Cursor: Set encoding to UTF-8 failed" -ForegroundColor Red
}
#[Console]::OutputEncoding = New-Object System.Text.UTF8Encoding $false
#[Console]::InputEncoding = New-Object System.Text.UTF8Encoding $false
#$OutputEncoding = [System.Text.UTF8Encoding]::new($false)
#$PSDefaultParameterValues['Out-File:Encoding'] = 'utf8'
#$PSDefaultParameterValues['Set-Content:Encoding'] = 'utf8'
#$PSDefaultParameterValues['Add-Content:Encoding'] = 'utf8'
Write-Host "Cursor: Set encoding to UTF-8 finished" -ForegroundColor Green
}
# <<< Cursor UTF-8 config <<<