Windows10 Powershell批量更改后缀名

操做系统:Windows10 1809html

使用工具:Powershellshell

命令工具

1 (dir '文件目录\*.原后缀名')|rename-item -newname { $_.name -replace '\.原后缀名','.要更改后缀名' } 

范例spa

1 (dir 'D:\My Documents\works\Downloads\powershell\*.txt')|rename-item -newname { $_.name -replace '\.txt','.log' } 

 

来自 <https://zhidao.baidu.com/question/384260033.html?qbl=relate_question_0&word=powershell%20%D0%DE%B8%C4%CE%C4%BC%FE%BA%F3%D7%BA>操作系统

相关文章
相关标签/搜索