diff options
author | Badlop <badlop@process-one.net> | 2007-12-04 23:41:52 +0000 |
---|---|---|
committer | Badlop <badlop@process-one.net> | 2007-12-04 23:41:52 +0000 |
commit | c30ddd3a072101cbfcc158b377d80086dd55414f (patch) | |
tree | c75c6fe804d7255d32b464a9c2d255d888ce7627 | |
parent | * .gitignore: Removed (EJAB-441) (diff) |
* contrib/extract_translations/extract_translations.erl: Don't
report [] to be translated. Identify unusued strings.
SVN Revision: 1022
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | contrib/extract_translations/extract_translations.erl | 7 |
2 files changed, 10 insertions, 2 deletions
@@ -1,3 +1,8 @@ +2007-12-05 Badlop <badlop@process-one.net> + + * contrib/extract_translations/extract_translations.erl: Don't + report [] to be translated. Identify unusued strings. + 2007-12-04 Badlop <badlop@process-one.net> * .gitignore: Removed (EJAB-441) diff --git a/contrib/extract_translations/extract_translations.erl b/contrib/extract_translations/extract_translations.erl index 01788c504..bd116b090 100644 --- a/contrib/extract_translations/extract_translations.erl +++ b/contrib/extract_translations/extract_translations.erl @@ -49,7 +49,7 @@ process(Dir, File, Used) -> case Used of unused -> ets:foldl(fun({Key, _}, _) -> - io:format("~p~n", [Key]) + io:format("Unused string: ~p~n", [Key]) end, ok, translations); _ -> ok @@ -122,7 +122,10 @@ process_string(_Dir, File, Str, Used) -> io:format("~n% ~s~n", [File]), ets:insert(files, {File}) end, - io:format("{~p, \"\"}.~n", [Str]), + case Str of + [] -> ok; + _ -> io:format("{~p, \"\"}.~n", [Str]) + end, ets:insert(translations, {Str, ""}); _ -> ok |