+###### Translation data, move out, see create-weblinks-itexi.py
+translations = {
+ 'ca': {
+ 'English': 'Català',
+ 'Other languages': 'Altres idiomes',
+ },
+ 'cs': {
+ 'English': 'Česky',
+ 'Other languages': 'Jiné jazyky',
+ },
+ 'de': {
+ 'English': 'Deutsch',
+ 'Other languages': 'Andere Sprachen',
+ },
+ 'es': {
+ 'English': 'Español',
+ 'Other languages': 'Otros idiomas',
+ },
+ 'fr': {
+ 'English': 'Français',
+ 'Other languages': 'Autres langues',
+ },
+ 'hu': {
+ 'English': 'Magyar',
+ 'Other languages': 'Más nyelvek',
+ },
+ 'it': {
+ 'English': 'Italiano',
+ 'Other languages': 'Altre lingue',
+ },
+ 'ja': {
+ 'English': '日本語',
+ 'Other languages': '他の言語',
+ },
+ 'nl': {
+ 'English': 'Nederlands',
+ 'Other languages': 'Andere talen',
+ },
+ 'zh': {
+ 'English': '中文',
+ 'Other languages': '其他语言',
+ },
+ }
+
+# needs at least: make -C po or make -C Documentation/po
+HAVE_GETTEXT = False
+
+#### this breaks on lilypond.org
+# Keep some freakin' gettext compatibility
+#if HAVE_GETTEXT:
+# import lilylib as ly;
+# global _;_=ly._
+#else: # poor mans translation
+# def _ (string, lang=os.environ['LANG']):
+# return translations.get (lang.split ('_')[0], {}).get (string, string)
+
+#### this works on lilypond.org
+def _ (string, lang):
+ return translations.get (lang.split ('_')[0], {}).get (string, string)
+
+
+exclude_manuals = [
+ '/music-glossary',
+ '/snippets',
+ '/internals',
+ '/contributor'