linux xargs 命令

find ./ -type f 'pyc'|xargs rm

我想删除本地的pyc 文件这个好像不对

阅读 1.9k
1 个回答
find -type f -name '*.pyc' -print0 | xargs -0 rm
find -type f -name '*.pyc' -delete  # 使用内建的delete操作,暂时没有和rm比对过性能
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题