Bug 24072 - "Usage" messages in initscripts can be more generic
"Usage" messages in initscripts can be more generic
Status: CLOSED DUPLICATE of bug 24068
Product: Red Hat Linux
Classification: Retired
Component: initscripts (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Bill Nottingham
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2001-01-15 16:44 EST by Christian Rose
Modified: 2014-03-16 22:18 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-01-15 16:44:24 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Christian Rose 2001-01-15 16:44:20 EST
In these messages;

#: ../rc.d/init.d/functions:270
msgid "Usage: status {program}\n"
#: ../rc.d/init.d/rawdevices:77
msgid "Usage: rawdevice {start|stop|status|restart}\n"
#: ../rc.d/init.d/random:56
msgid "Usage: %s {start|stop|status|restart|reload}\n"
#: ../rc.d/init.d/netfs:108
msgid "Usage: %s {start|stop|restart|reload|status}\n"
#: ../rc.d/init.d/network:200
msgid "Usage: %s {start|stop|restart|reload|status|probe}\n"
#: squid.init:130
msgid "Usage: %s {start|stop|status|reload|restart|condrestart}\n"
#: am-utils.init:92
msgid "Usage: %s {start|stop|restart|reload|condrestart|status}\n"
#: syslog.init:82
msgid "Usage: syslog {start|stop|status|restart|condrestart}"

the name of the script to run should of course not be translated. i think
it is safe to replace the name of the scripts here with %s, like is done in
some of these. Also, the program options in these messages should not be
altered in translations, so they could get replaced with %s too:
"Usage: %s %s"

Please also note that the ordering of the options is inconsistent, and also
the use of \n. Sorry if I'm nit-picky.

However, when there is a parameter with a symbolic name, it really should
be left for translation:
#: ../rc.d/init.d/functions:172
msgid "Usage: killproc {program} [signal]\n"
could be
"Usage: %s %s [signal]\n"

Everything is of course IMHO, and I can of course be wrong about my
proposed scheme fitting other languages. But I think it will work and help
whenever initscripts is updated and a new option "foo" is added to the
syntax to a script, for example.
Comment 1 Bill Nottingham 2001-01-15 16:53:27 EST
Um, you can't translate a function name (well, you *can*, it would just be

As for the various messages, please see resolution to previous bug report.

*** This bug has been marked as a duplicate of 24068 ***
Comment 2 Christian Rose 2001-01-15 20:35:13 EST
> Um, you can't translate a function name (well, you *can*, it would just be

That's exactly what I meant. Including a function name in a message marked for
translation is unnecessary, it can be made more elegant with %s. Function names
and file names are two of the rare exceptions to the rule "never use
substitution in messages".

I will split up this bug.
Comment 3 Christian Rose 2001-01-15 22:15:52 EST
See bug 24085, bug 24086, bug 24087, and bug 24088.

Note You need to log in before you can comment on or make changes to this bug.