HomeTips & TricksUse standardized source filesWrite your own commands
User Manual UDO > UDO in practice > Tips & Tricks Index

Use standardized file names

UDO does not concern how you name the files which make up your UDO source text document. But for structurized workflows, it can be very useful to create your own standards. Especially when you exchange work with other persons, you should even name files in a standardized way.

As soon as you are going to create documentations for multiple languages, you should use English file names if you're not completely sure that all co-authors and colleagues really understand your language (e.g. German) and that no file system they are working with, has any difficulties with e.g. German umlauts in file names.

Here is our suggestion:

.u Mnemonic: .u like UDO. This is the main file for the document, e.g. manual.u.
.ui Mnemonic: .ui like UDO Include. These files are included by the .u file. These files should contain just more control commands, but no text which might want to be localized.
.uli Mnemonic: .uli like UDO Library Include. Files which can be used from a library for several projects at the same time, e.g. macro definitions, hyphenation rules, etc.
.de All files with German texts.
.en All files with English texts.
.sv All files with Swedish texts. (If you wonder why we do not suggest .se for these, here is our explanation: sv is the ISO descriptor for the language Swedish, while SE is the ISO descriptor for the country Sweden. This is mixed up pretty often, like e.g. with Czech (cs) and Czechia (CZ).
.fr_CA Now you got the idea, right? This file extension would define that the document content of the file is written in Canadian French. The ISO descriptors for languages and countries can be used that easily. – If you don't have to differenciate for French that way, a simple .fr will be fine, of course.

If you name your files this way, you will simply have to add more !include commands in the .ui files when you add another localization to your documentation. Just copy your e.g. .en files and change the extension of the copied files to the desired language descriptor.

# manual.u
# --------
!include praeamble.ui

!begin_document
!include intro.ui
!include ref.ui
!include appendix.ui
!end_document

# intro.ui
# --------
!ifset [de]
!include intro.de
!endif
!ifset [en]
!include intro.en
!endif

Copyright © www.udo-open-source.org (Contact)
Last updated on May 19, 2014

HomeTips & TricksUse standardized source filesWrite your own commands