help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-bash] How to escape the format string used by printf?


From: Peng Yu
Subject: [Help-bash] How to escape the format string used by printf?
Date: Mon, 26 Aug 2019 13:38:53 -0500

Hi,

For any string, I need to use it literately in `format` of `printf`.

printf: printf [-v var] format [arguments]

Certain things, for example, %, must be escaped.

Is there a builtin or well-tested way to efficiently and correctly
escape any string so that they can be used as `format` of `printf`
literally? Thanks.

-- 
Regards,
Peng



reply via email to

[Prev in Thread] Current Thread [Next in Thread]