比如想给py文件开头都加上coding:utf-8防止python2.7运行报错
就这么写:
find app -name “*.py” -exec sed -i ‘’ -e ‘1i
#coding:utf-8’ {} ;
linu Mac 批量 文件 行首 添加 字符

参考:https://my.oschina.net/jsk/blog/166974

谷歌大法好啊,搜狗一下午没找到解决方案

相关文章:

  • 2021-11-08
  • 2022-12-23
  • 2021-08-12
  • 2022-12-23
  • 2021-08-09
  • 2021-10-28
  • 2021-07-26
  • 2021-10-03
猜你喜欢
  • 2022-12-23
  • 2021-05-16
  • 2021-12-06
  • 2022-12-23
相关资源
相似解决方案