test/testps8.ps1
raw| 1 | # This script demonstrates how to use Unicode file names |
| 2 | # in a PowerShell script. |
| 3 | # This script is in UTF-8 encoding, with BOM. |
| 4 | |
| 5 | $env:DOS2UNIX_DISPLAY_ENC = "utf8" |
| 6 | |
| 7 | dos2unix -i uni_el_αρχείο.txt uni_zh_文件.txt |
| 8 | |
| 9 | echo "test select-string:" |
| 10 | |
| 11 | # select-string requires a BOM. |
| 12 | $env:DOS2UNIX_DISPLAY_ENC = "utf8bom" |
| 13 | dos2unix -i uni* | select-string -encoding utf8 -pattern αρχ |
| 14 | |
| 15 | $env:DOS2UNIX_DISPLAY_ENC = "" |