diff --git a/Documentation/Scripts/generateExamples.py b/Documentation/Scripts/generateExamples.py index 2cb8731f9b..5242c38481 100644 --- a/Documentation/Scripts/generateExamples.py +++ b/Documentation/Scripts/generateExamples.py @@ -130,6 +130,8 @@ OPTION_OUTPUT_FILE = 4 fstate = OPTION_NORMAL +escapeBS = re.compile("\\\\") +doubleBS = "\\\\\\\\" ################################################################################ ### @brief generate arangosh example headers with functions etc. needed later @@ -326,8 +328,8 @@ def generateArangoshOutput(testName): testName, testName, value[TESTLINES][0][2], - OutputDir, - MapSourceFiles[testName] + escapeBS.sub(doubleBS, OutputDir), + escapeBS.sub(doubleBS, MapSourceFiles[testName]) ) except Exception as x: print x @@ -404,8 +406,8 @@ def generateArangoshRun(testName): testName, testName, startLineNo, - OutputDir, - MapSourceFiles[testName], + escapeBS.sub(doubleBS, OutputDir), + escapeBS.sub(doubleBS, MapSourceFiles[testName]), value[STRING].lstrip().rstrip()) if testName in ArangoshExpect: