*Localization of CVSTrac* All the text generated by CVSTrac is American English. But dates can be displayed in the local language and format. To show dates in the local language, do this: *: Create bash script to run CVSTrac in required locale. Example : _uk-cvstrac_ #!/bin/bash LANG=uk_UA.KOI8-U /usr/local/bin/cvstrac $* *: Replace "cvstrac" in your scripts by name of your new script (uk-cvstrac, in my case). You can set LANG environment variable in xinet.d configuration (see "man xinetd.conf" for details): env LANG=uk_UA.KOI8-U or in .htaccess (in case of CGI script): SetEnv LANG uk_UA.KOI8-U If you want to run a localized CVSTrac in chroot environment (such as described in ChrootJailForCvstrac), use the following command to find all files required by the cvstrac binary. strace -o logfile -e trace=file cvstrac ... Then "logfile" will list file operations that cvstrac tried, whether they succeeded or not. See also CvsTracLocalization ---- *Localization of CVSTrac 2.0* SQLite3 officially supports only UTF-8 as text, but almost functions work fine even for other encodings. So there is two way to localize cvstrac 2.0.{linebreak} One is using UTF-8, the other is using local encoding. *: UTF-8 *:: Advantage *::: Officially supported by SQLite3. *::: Able to support multiple languages. *:: Defect *::: If sources are written in encodings which is not compatible to UTF-8, encoding conversions are required for each access to the repository. *::: Can not use local encoding for filenames. *:: Usage *::: Convert encoding of the project database. $ mv .db _old.db $ sqlite3 _old.db .dump | iconv -f -t UTF-8 | \ sqlite3 .db *::: Set the environment variable to UTF-8. *::: If sources are written in encodings which is not compatible to UTF-8, *:::: Add a converting command to each commands at "Diff and Filter Programs" of Setup.{linebreak} For example, File Diff: rcsdiff -q -r'%V1' -r'%V2' -u '%F' | iconv -f -t UTF-8 File List: co -q -p'%V' '%F' | iconv -f -t UTF-8 | diff -c /dev/null - File Filter: iconv -f -t UTF-8 *:::: Apply the patch [808] and customize rlog command.{linebreak} $ sqlite3 .db sqlite> insert into config values('rlog', ...> 'rlog ''-d%TR'' ''%F'' 2>/dev/null | ' || ...> 'iconv -f -t UTF-8'); *::: Apply the patch [810] for the highlight() function.{linebreak} (This patch doesn't support grapheme clusters.) *: local encoding (equivalent to 1.2) *:: Advantage *::: No encoding conversion is required. *::: Works with local encoding for filenames. *:: Defect *::: The search() function may match with not matching text.{linebreak} (But "match with not matching" problem is not severe.) *::: The highlight() function may split in characters.{linebreak} (But this problem is accepted by many users using multibyte encoding.) *::: In Big5 or ShiftJIS, '_', '[', '|' and '{...}' format may be broken.{linebreak} (But the problems of '_' and '[' are very rare case.){linebreak} To avoid the problem of '|', apply the patch [813] and quote the broken character by {quote: {quote: }}.{linebreak} The problem of '{...}' is complicated. For example in ShiftJIS, the katakana-bo and katakana-ma character in the {quote: {link: url text}} markup cause unexpected output. Using {quote: ...} is the only way to avoid this problem. *:: Usage *::: Set the environment variable to the local encoding. *::: Apply the patch [811] for substr() and length() functions.{linebreak} (This patch is not required if you don't use these functions in Reports.)