diff options
author | Björn Jacke <bj@sernet.de> | 2010-01-18 23:39:19 +0100 |
---|---|---|
committer | Björn Jacke <bj@sernet.de> | 2010-01-18 23:45:05 +0100 |
commit | bd3c922e2bc1a163efc1d8c9cb59578bebb79616 (patch) | |
tree | f23544c18ce2c0ac8e9ff4b4f0302e4172aa1794 /source3/utils/net_registry.c | |
parent | c3ef7a3d96763719de1df679d50fb8a00d1f7391 (diff) | |
download | samba-bd3c922e2bc1a163efc1d8c9cb59578bebb79616.tar.gz samba-bd3c922e2bc1a163efc1d8c9cb59578bebb79616.tar.xz samba-bd3c922e2bc1a163efc1d8c9cb59578bebb79616.zip |
s3/net: split up some printable stings to ease i18n
If we put strings like "Usage:" into separate _() macros and not the whole
"Usage:..." string we can cover much more messages by only one single
translation. The drawback is that the message in the sources looks less pretty.
Diffstat (limited to 'source3/utils/net_registry.c')
-rw-r--r-- | source3/utils/net_registry.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/source3/utils/net_registry.c b/source3/utils/net_registry.c index 711c1112753..9d953f3e24a 100644 --- a/source3/utils/net_registry.c +++ b/source3/utils/net_registry.c @@ -130,8 +130,8 @@ static int net_registry_enumerate(struct net_context *c, int argc, int ret = -1; if (argc != 1 || c->display_usage) { - d_printf(_("Usage: net registry enumerate <path>\n")); - d_printf(_("Example: net registry enumerate " + d_printf(_("Usage:"),_(" net registry enumerate <path>\n")); + d_printf(_("Example:"), _(" net registry enumerate " "'HKLM\\Software\\Samba'\n")); goto done; } @@ -182,8 +182,8 @@ static int net_registry_createkey(struct net_context *c, int argc, int ret = -1; if (argc != 1 || c->display_usage) { - d_printf(_("Usage: net registry createkey <path>\n")); - d_printf(_("Example: net registry createkey " + d_printf(_("Usage:"),_(" net registry createkey <path>\n")); + d_printf(_("Example:"), _(" net registry createkey " "'HKLM\\Software\\Samba\\smbconf.127.0.0.1'\n")); goto done; } @@ -235,8 +235,8 @@ static int net_registry_deletekey(struct net_context *c, int argc, int ret = -1; if (argc != 1 || c->display_usage) { - d_printf(_("Usage: net registry deletekey <path>\n")); - d_printf(_("Example: net registry deletekey " + d_printf(_("Usage:"),_(" net registry deletekey <path>\n")); + d_printf(_("Example:"),_(" net registry deletekey " "'HKLM\\Software\\Samba\\smbconf.127.0.0.1'\n")); goto done; } @@ -247,14 +247,14 @@ static int net_registry_deletekey(struct net_context *c, int argc, werr = open_hive(ctx, argv[0], REG_KEY_WRITE, &hivekey, &subkeyname); if (!W_ERROR_IS_OK(werr)) { - d_fprintf(stderr, _("open_hive failed: %s\n"), - win_errstr(werr)); + d_fprintf(stderr, "open_hive ", _("failed"), + ": %s\n", win_errstr(werr)); goto done; } werr = reg_deletekey(hivekey, subkeyname); if (!W_ERROR_IS_OK(werr)) { - d_fprintf(stderr, _("reg_deletekey failed: %s\n"), + d_fprintf(stderr, "reg_deletekey ", _("failed"), ": %s\n", win_errstr(werr)); goto done; } @@ -276,7 +276,7 @@ static int net_registry_getvalue_internal(struct net_context *c, int argc, TALLOC_CTX *ctx = talloc_stackframe(); if (argc != 2 || c->display_usage) { - d_fprintf(stderr, _("usage: net rpc registry getvalue <key> " + d_fprintf(stderr, _("usage:"),_(" net rpc registry getvalue <key> " "<valuename>\n")); goto done; } @@ -325,7 +325,7 @@ static int net_registry_setvalue(struct net_context *c, int argc, TALLOC_CTX *ctx = talloc_stackframe(); if (argc < 4 || c->display_usage) { - d_fprintf(stderr, _("usage: net rpc registry setvalue <key> " + d_fprintf(stderr, _("usage:"),_(" net rpc registry setvalue <key> " "<valuename> <type> [<val>]+\n")); goto done; } @@ -380,7 +380,7 @@ static int net_registry_deletevalue(struct net_context *c, int argc, int ret = -1; if (argc != 2 || c->display_usage) { - d_fprintf(stderr, _("usage: net rpc registry deletevalue <key> " + d_fprintf(stderr, _("usage:"),_(" net rpc registry deletevalue <key> " "<valuename>\n")); goto done; } @@ -424,8 +424,8 @@ static int net_registry_getsd(struct net_context *c, int argc, access_mask = REG_KEY_READ; if (argc != 1 || c->display_usage) { - d_printf(_("Usage: net registry getsd <path>\n")); - d_printf(_("Example: net registry getsd " + d_printf(_("Usage:"),_(" net registry getsd <path>\n")); + d_printf(_("Example:"),_(" net registry getsd " "'HKLM\\Software\\Samba'\n")); goto done; } |