From b56035d4f58ac81c5b63e79a22ba35ada5efbb1f Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 26 Sep 2011 21:28:03 -0400 Subject: [PATCH] I18N - Localized 'shell' command. --- src/commands/CmdShell.cpp | 10 ++++++---- src/en-US.h | 3 +++ 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/src/commands/CmdShell.cpp b/src/commands/CmdShell.cpp index 09e17d500..7ae17ad9b 100644 --- a/src/commands/CmdShell.cpp +++ b/src/commands/CmdShell.cpp @@ -25,6 +25,8 @@ // //////////////////////////////////////////////////////////////////////////////// +#define L10N // Localization complete. + #include #include #include @@ -52,9 +54,9 @@ int CmdShell::execute (std::string&) Color bold (Color::nocolor, Color::nocolor, false, true, false); std::cout << (context.color () ? bold.colorize (PACKAGE_STRING) : PACKAGE_STRING) << " shell\n\n" - << "Enter any task command (such as 'list'), or hit 'Enter'.\n" - << "There is no need to include the 'task' command itself.\n" - << "Enter 'quit' (or 'bye', 'exit') to end the session.\n\n"; + << STRING_CMD_SHELL_HELP1 << "\n" + << STRING_CMD_SHELL_HELP2 << "\n" + << STRING_CMD_SHELL_HELP3 << "\n\n"; // Make a copy because context.clear will delete them. std::string permanent_overrides; @@ -116,7 +118,7 @@ int CmdShell::execute (std::string&) catch (...) { - std::cerr << "Unknown error." << "\n"; + std::cerr << STRING_UNKNOWN_ERROR << "\n"; } } } diff --git a/src/en-US.h b/src/en-US.h index 1efe3422b..9f4f76491 100644 --- a/src/en-US.h +++ b/src/en-US.h @@ -316,6 +316,9 @@ #define STRING_CMD_IMPORT_BAD_ATT "Unrecognized attribute '{1}'" #define STRING_CMD_IMPORT_NOT_JSON "Not a JSON object: {1}" #define STRING_CMD_SHELL_USAGE "Launches an interactive shell" +#define STRING_CMD_SHELL_HELP1 "Enter any task command (such as 'list'), or hit 'Enter'." +#define STRING_CMD_SHELL_HELP2 "There is no need to include the 'task' command itself." +#define STRING_CMD_SHELL_HELP3 "Enter 'quit' (or 'bye', 'exit') to end the session." #define STRING_CMD_SYNCH_USAGE "(Not implemented for 2.0.0beta2)" #define STRING_CMD_DIAG_USAGE "Shows information needed when reporting a problem." #define STRING_CMD_DIAG_PLATFORM "Platform"