python 与 powershell交互问题。
问题环境:使用python脚本调用windows窗口选择文件模块,如filename = “测试”。输入至powershell的$filename变量。现在呢powershell无法识别非ascii的编码,
问题:
powershell如何进行转码,假设:
a = “中国” #如果不转码的话输出就是乱码
使用什么方法,可以把编码转成utf8 或者能够识别中文的格式。
跪求。。。。。在线等。。。。。 powershell如何进行转码为utf8,我是英文版的win7 这是python问题还是powershell问题?
这个帖子里的东西对你有没有用?
stackoverflow.com/questions/22349139/utf8-output-from-powershell 回复 3# whitelotus19
具体来说应该是powershell的问题。
页:
[1]