mirror of
https://github.com/tldr-pages/tldr.git
synced 2024-09-11 03:55:31 +03:00
xargs: improve example command (#13396)
This commit is contained in:
parent
5acc6ef400
commit
333cfc1355
@ -12,9 +12,9 @@
|
||||
|
||||
`{{arguments_source}} | xargs sh -c "{{command1}} && {{command2}} | {{command3}}"`
|
||||
|
||||
- Delete all files with a `.backup` extension (`-print0` uses a null character to split file names, and `-0` uses it as delimiter):
|
||||
- Gzip all files with `.log` extension taking advantage of multiple threads (`-print0` uses a null character to split file names, and `-0` uses it as delimiter):
|
||||
|
||||
`find . -name '*.backup' -print0 | xargs -0 rm -v`
|
||||
`find . -name '*.log' -print0 | xargs -0 -P {{4}} -n 1 gzip`
|
||||
|
||||
- Execute the command once per argument:
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user