diff options
author | Darkvater <Darkvater@openttd.org> | 2006-01-28 11:10:52 +0000 |
---|---|---|
committer | Darkvater <Darkvater@openttd.org> | 2006-01-28 11:10:52 +0000 |
commit | dba8dc56c6f851958739f09fe27428c4830695eb (patch) | |
tree | b26268f6dc286f41d9ceb132d153a34fa9acc679 /strgen | |
parent | e9519c20b011a86588420b5ab0cd8472d48d7eb3 (diff) | |
download | openttd-dba8dc56c6f851958739f09fe27428c4830695eb.tar.xz |
(svn r3459) - CodeChange: add help-output to strgen and also verbose variants of the switches
Diffstat (limited to 'strgen')
-rw-r--r-- | strgen/strgen.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/strgen/strgen.c b/strgen/strgen.c index 1ebb11444..45846d45e 100644 --- a/strgen/strgen.c +++ b/strgen/strgen.c @@ -1215,16 +1215,29 @@ int CDECL main(int argc, char* argv[]) return 0; } - if (argc > 1 && !strcmp(argv[1], "-t")) { + if (argc > 1 && (!strcmp(argv[1], "-t") || !strcmp(argv[1], "--todo"))) { show_todo = 1; argc--, argv++; } - if (argc > 1 && !strcmp(argv[1], "-w")) { + if (argc > 1 && (!strcmp(argv[1], "-w") || !strcmp(argv[1], "--warning"))) { show_todo = 2; argc--, argv++; } + if (argc > 1 && (!strcmp(argv[1], "-h") || + !strcmp(argv[1], "--help") || !strcmp(argv[1], "-?"))) { + puts("strgen - $Revision$"); + puts(" -v | --version print version information and exit"); + puts(" -h | -? | --help print this help message and exit"); + puts(" -t | --todo replace any untranslated strings with '<TODO>'"); + puts(" -w | --warning print a warning for any untranslated strings"); + puts(" Run without parameters strgen will search for lang/english.txt and"); + puts(" parse it. Passing an argument, strgen will translate that language file"); + puts(" with lang/english.txt as a reference."); + return 0; + } + if (argc == 1) { _masterlang = true; |