eygle.com   eygle.com
eygle.com  
 

« Linux/Unix下如何删除具有特殊字符的文件 | Digest首页 | Linux中如何校验哪些端口正在监听 »

Linux中如何替换文件名中的空格

链接:

用 tr :

find . -type f -name "* *" -print |
while read name; do
na=$(echo $name | tr ' ' '_')


if [[ $name != $na ]]; then
mv "$name" $na
fi
done

记录一下备忘。

-The End-

By eygle on 2006-11-12 12:20 | Comments (0) | Posted to 网站技术 |Pageviews:

相关文章 随机文章
  • Linux的rsh设置及no route to host解决
  • 用SecureCRT来上传和下载数据
  • 了解Linux的时钟
  • vmstat 命令的用法说明
  • Linux Memory Management or 'Why is there no free RAM?'
  • 决定智商的基因
    IPtables常用命令及参数指南
    Oracle9i的监听器动态注册
    甲骨文在2008财年第二季度客户迅猛增长
    Linux Memory Management or 'Why is there no free RAM?'
    网上相关主题:
    Google

    留言 (0)

    发表留言:



    Remember Me?
    (输入验证码后方可评论,谢谢支持)



    CopyRight © 2004 eygle.com, All rights reserved.