0

While I was reading the document of some Linux utilities, I found that they always quote strings using ` and '. For example, below is an excerpt from the man page of the find utility.

       -exec command {} +
              This variant of the -exec action runs the specified
              command on the selected files, but the command line is
              built by appending each selected file name at the end; the
              total number of invocations of the command will be much
              less than the number of matched files.  The command line
              is built in much the same way that xargs builds its
              command lines.  Only one instance of `{}' is allowed
              within the command, and it must appear at the end,
              immediately before the `+'; it needs to be escaped (with a
              `\') or quoted to protect it from interpretation by the
              shell.  The command is executed in the starting directory.
              If any invocation with the `+' form returns a non-zero
              value as exit status, then find returns a non-zero exit
              status.  If find encounters an error, this can sometimes
              cause an immediate exit, so some pending commands may not
              be run at all.  For this reason -exec my-
              command ... {} + -quit may not result in my-command
              actually being run.  This variant of -exec always returns
              true.

As you can see, there are several such cases like `{}', `\' and `+'. Why they don't use a pair of single quotes or backtick?

Stephen Kitt
  • 434,908
  • In normal properly formatted literary English text the quotation marks would be sloped. The actual marks are ‘this’ or ‛this’ or “this” or ‟this”. The usage in the man page would be an affectation attempting to emulate the literary format. You are right, it is a bit pointless in that context. cf. https://en.wikipedia.org/wiki/Quotation_marks_in_English#Typing_quotation_marks_on_a_computer_keyboard – Rizzer Apr 09 '22 at 09:52
  • As far as the double `backtick` goes, that has a specific meaning in the shell. It indicates a subshell, same as $( ... ) – Rizzer Apr 09 '22 at 09:59

0 Answers0