Skip to main content
replaced http://unix.stackexchange.com/ with https://unix.stackexchange.com/
Source Link
deleted 158 characters in body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284

Also, as Stephane Chazelas points out in a comment, GNU xargs requires -0 and -r, whereas FreeBSD xargs only requires -0 (and has no -r option), and some xargs don't support -0 at all. So it's best to just stick to POSIX features of find (see next section) and skip xargs.

Also, as Stephane Chazelas points out in a comment, GNU xargs requires -0 and -r, whereas FreeBSD xargs only requires -0, and some xargs don't support -0 at all. So it's best to just stick to POSIX features of find (see next section) and skip xargs.

Also, GNU xargs requires -0 and -r, whereas FreeBSD xargs only requires -0 (and has no -r option), and some xargs don't support -0 at all. So it's best to just stick to POSIX features of find (see next section) and skip xargs.

edited body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284

If you need to use shell features in the command, such as redirecting the output or stripping onan extension off the filename or something similar, you can make use of the sh -c construct. You should know a few things about this:

If you need to use shell features in the command, such as redirecting the output or stripping on extension off the filename or something similar, you can make use of the sh -c construct. You should know a few things about this:

If you need to use shell features in the command, such as redirecting the output or stripping an extension off the filename or something similar, you can make use of the sh -c construct. You should know a few things about this:

Both find and xargs are parts of findutils, not coreutils.
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
Loading
added 425 characters in body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
edited body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
added 439 characters in body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
added 426 characters in body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
added 426 characters in body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
added 591 characters in body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
added 591 characters in body
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading
Source Link
Wildcard
  • 37.5k
  • 30
  • 149
  • 284
Loading