We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
通过代码生成器生成的文件如AppService、Dto中有中文注释的,在MacOS下会是乱码,Windows下没有问题。 经过排查发现是生成的文件编码默认为ANSI格式,建议修改为UTF-8.
The text was updated successfully, but these errors were encountered:
ABPHelper使用File.WriteAllTextAsync生成文件,该方法默认使用的是UTF-8(无BOM),所以理论上应该不会产生乱码。
File.WriteAllTextAsync
你的DTO文件用的什么编码?我怀疑在解析的时候就已经乱了。
Sorry, something went wrong.
这个和系统默认编码有关系不,如系统默认编码是GB2312。
ABPHelper使用File.WriteAllTextAsync生成文件,该方法默认使用的是UTF-8(无BOM),所以理论上应该不会产生乱码。 你的DTO文件用的什么编码?我怀疑在解析的时候就已经乱了。
文档写的使用UTF-8,和系统编码应该没关系。
如果DTO源码使用的GB2312,有可能会导致这个错误,因为读取的时候也是按照UTF-8
No branches or pull requests
通过代码生成器生成的文件如AppService、Dto中有中文注释的,在MacOS下会是乱码,Windows下没有问题。
经过排查发现是生成的文件编码默认为ANSI格式,建议修改为UTF-8.
The text was updated successfully, but these errors were encountered: