由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Unix版 - Re: how to change all the files .cpp to .C
相关主题
文件改名一问?which shell is best?
A question about command timehow to let awk not print?
How to change file time stampequivilent $REMOTEHOST in ksh
问题:gentoo的gcc编译的CFLAGSshell programming问题:如何同时run多个作业
how to run background process after logoutChange shell to tcsh?
关于cxterm的问题.cshrc?.login?.profile?
[转载] About the historybash 彩色 shell prompt
如何单步执行shell?如何在当前目录下查找替换一个串?
相关话题的讨论汇总
话题: cpp话题: files话题: change
进入Unix版参与讨论
1 (共1页)
h******a
发帖数: 198
1
now I could only think up one way:
foreach file(*.cpp)
mv $file `basename $file .cpp`.C
end
for tcsh/csh
p*a
发帖数: 592
2
ls -1 *.cpp | sed 's/\(.*\)\.cpp/\1\.cpp \1\.C/' | xargs -n2 mv

【在 h******a 的大作中提到】
: now I could only think up one way:
: foreach file(*.cpp)
: mv $file `basename $file .cpp`.C
: end
: for tcsh/csh

1 (共1页)
进入Unix版参与讨论
相关主题
如何在当前目录下查找替换一个串?how to run background process after logout
生成script文件的问题关于cxterm的问题
how to redirect error output under unix[转载] About the history
[转载] 再请教高手如何单步执行shell?
文件改名一问?which shell is best?
A question about command timehow to let awk not print?
How to change file time stampequivilent $REMOTEHOST in ksh
问题:gentoo的gcc编译的CFLAGSshell programming问题:如何同时run多个作业
相关话题的讨论汇总
话题: cpp话题: files话题: change