]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
doc: highlight -HLP options
authorPádraig Brady <P@draigBrady.com>
Fri, 16 Jan 2026 14:35:44 +0000 (14:35 +0000)
committerPádraig Brady <P@draigBrady.com>
Wed, 21 Jan 2026 13:51:40 +0000 (13:51 +0000)
* src/system.h (emit_symlink_recurse_options): Highlight -HLP,
for chmod, chcon etc.

src/system.h

index 1d52f6300b11cec6e94d46520d4bf1db8963ccb4..68d3e2d459bb733ddd4ce671daac3b1c996e60fc 100644 (file)
@@ -710,22 +710,31 @@ the VERSION_CONTROL environment variable.  Here are the values:\n\
 "), stdout);
 }
 
+#define emit_symlink_recurse_options(default_opt) \
+ emit_symlink_recurse_options_ (PROGRAM_NAME, default_opt)
 static inline void
-emit_symlink_recurse_options (char const *default_opt)
+emit_symlink_recurse_options_ (char const* program, char const *default_opt)
 {
       printf (_("\
 \n\
 The following options modify how a hierarchy is traversed when the -R\n\
 option is also specified.  If more than one is specified, only the final\n\
 one takes effect. %s is the default.\n\
-\n\
-  -H                     if a command line argument is a symbolic link\n\
-                         to a directory, traverse it\n\
-  -L                     traverse every symbolic link to a directory\n\
-                         encountered\n\
-  -P                     do not traverse any symbolic links\n\
 \n\
 "), default_opt);
+      oputs_ (program, _("\
+  -H\n\
+         if a command line argument is a symlink to a directory, traverse it\n\
+"));
+      oputs_ (program, _("\
+  -L\n\
+         traverse every symbolic link to a directory encountered\n\
+"));
+      oputs_ (program, _("\
+  -P\n\
+         do not traverse any symbolic links\n\
+\n\
+"));
 }
 
 static inline void