简短精悍的代码,特别适合开源项目使用。
for /r %%F in (*.as) DO ( move "%%F" tmp.txt type copyright.txt > "%%F" type tmp.txt >> "%%F" del tmp.txt )
把上述代码保存为bat,另外同一级目录放置copyright.txt
修改(*.as)为相应的文件后缀,就可以对相应的代码文件加版权头
简短精悍的代码,特别适合开源项目使用。
for /r %%F in (*.as) DO ( move "%%F" tmp.txt type copyright.txt > "%%F" type tmp.txt >> "%%F" del tmp.txt )