fix(core): Ensure manipulating config with UTF8 encoding#4644
fix(core): Ensure manipulating config with UTF8 encoding#4644niheaven merged 5 commits intoScoopInstaller:developfrom
Conversation
There was a problem hiding this comment.
Maybe New-Item is another choice.
I found in its docs that: (-ItemType File)
When you create a file using this method, the resulting file is encoded as UTF-8 without a byte-order-mark (BOM).
Fixes ScoopInstaller#4629 Signed-off-by: Chawye Hsu <chawyehsu@hotmail.com>
3f6f60f to
ff9d0ca
Compare
|
I've updated the implementation by referring the simpler Puppet.Dsc's implementation and updated the tests. The tests failed under WindowsPowerShell on CI, which can't be reproduced on my local environment. @niheaven Need your help. You may look at and review the new commits and see if it can be bundled into the upcoming release. |
|
I'll check it tomorrow. |
|
@chawyehsu It is a bug of Pester/PS5 when test file contains non-ASCII characters. Using Although change |
This was introduced in #4644 and only occurred in non-Unicode system
Description
Use utf8 encoding in scoop's and aria2's config
Motivation and Context
Fixes #4629
How Has This Been Tested?
New unit tests introduced.
Checklist: