summaryrefslogtreecommitdiff
path: root/tools/rst2xetex.py
diff options
context:
space:
mode:
Diffstat (limited to 'tools/rst2xetex.py')
-rwxr-xr-xtools/rst2xetex.py27
1 files changed, 27 insertions, 0 deletions
diff --git a/tools/rst2xetex.py b/tools/rst2xetex.py
new file mode 100755
index 000000000..277315a08
--- /dev/null
+++ b/tools/rst2xetex.py
@@ -0,0 +1,27 @@
+#!/usr/bin/env python
+# .. coding: utf8
+
+# $Id$
+# Author: Günter Milde
+# Copyright: This module has been placed in the public domain.
+
+"""
+A minimal front end to the Docutils Publisher, producing XeLaTeX source code.
+"""
+
+try:
+ import locale
+ locale.setlocale(locale.LC_ALL, '')
+except:
+ pass
+
+from docutils.core import publish_cmdline
+
+description = ('Generates XeLaTeX documents from standalone reStructuredText '
+ 'sources. '
+ 'Reads from <source> (default is stdin) and writes to '
+ '<destination> (default is stdout). See '
+ '<http://docutils.sourceforge.net/docs/user/latex.html> for '
+ 'the full reference.')
+
+publish_cmdline(writer_name='xetex', description=description)