问答

linux 求解

作者:admin 2021-04-21 我要评论

find . -type f -name "*.jpg" -print | xargs tar -czvf images.tar.gz 请问这里的-print 是啥意思?为啥前面有一个"-" ### man里面写得很清楚了,请看文档 -pr...

在说正事之前,我要推荐一个福利:你还在原价购买阿里云、腾讯云、华为云服务器吗?那太亏啦!来这里,新购、升级、续费都打折,能够为您省60%的钱呢!2核4G企业级云服务器低至69元/年,点击进去看看吧>>>)
find . -type f -name "*.jpg" -print | xargs tar -czvf images.tar.gz

请问这里的-print 是啥意思?为啥前面有一个"-"

###

man里面写得很清楚了,请看文档

-print True; print the full file name on the standard output, followed by a newline. If you are piping the output of find into another program and there is the faintest possibility that the files which you are searching for might contain a newline, then you should seriously consider using the -print0 option instead of -print. See the UNUSUAL FILE‐AMES section for information about how unusual characters in filenames are handled.

版权声明:本文转载自网络,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。本站转载出于传播更多优秀技术知识之目的,如有侵权请联系QQ/微信:153890879删除

相关文章
  • linux 求解

    linux 求解

  • 前端排版问题(css),关于两个上下元素

    前端排版问题(css),关于两个上下元素

  • export { default as } from 'index.js

    export { default as } from 'index.js

  • linux shell 脚本求指教

    linux shell 脚本求指教

腾讯云代理商
海外云服务器