Skip to content

Commit ad483b4

Browse files
committed
further fix for bruderstein#92
- switch to html version of docu, because singlehtml doesn't provide an index/search - adapted zip and msi build therefore
1 parent 302c5fb commit ad483b4

File tree

5 files changed

+24
-12
lines changed

5 files changed

+24
-12
lines changed

appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ after_build:
4545
- if "%configuration%"=="Release" cd "%APPVEYOR_BUILD_FOLDER%"\docs
4646
- if "%configuration%"=="Release" python -m pip install --upgrade pip
4747
- if "%configuration%"=="Release" pip install -U sphinx
48-
- if "%configuration%"=="Release" make.bat singlehtml
48+
- if "%configuration%"=="Release" make.bat html
4949

5050
- cd "%APPVEYOR_BUILD_FOLDER%"\installer
5151
- set WIX_PATH="C:\Program Files (x86)\WiX Toolset v3.11\bin"

installer/PythonScript.wxs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,7 @@
4040
</Directory>
4141
</Directory>
4242
<Directory Id="D_doc" Name="doc">
43-
<Directory Id="D_DocPythonScript" Name="PythonScript">
44-
<Component Id="C_PythonScript.chm" Guid="*">
45-
<RemoveFile Id="Remove_F_PythonScript.chm" Name="PythonScript.chm" On="install"/>
46-
<File Id="F_PythonScript.chm" KeyPath="yes" Name="PythonScript.chm" Source="$(var.baseDir)\docs\build\singlehtml\index.html" />
47-
</Component>
48-
</Directory>
43+
<Directory Id="D_DocPythonScript" Name="PythonScript" />
4944
</Directory>
5045
<Component Id="C_pythonscript.dll" Guid="*">
5146
<RemoveFile Id="Remove_F_pythonscript.dll" Name="PythonScript.dll" On="install"/>
@@ -69,7 +64,7 @@
6964
<ComponentGroupRef Id="CG_PythonLib" />
7065
</Feature>
7166
<Feature Id="FT_Help" Title="Help" AllowAdvertise="no" Description="HTML files with documentation for all the classes, methods and enums in PythonScript">
72-
<ComponentRef Id="C_PythonScript.chm" />
67+
<ComponentGroupRef Id="CG_HtmlDocs" />
7368
</Feature>
7469
<Feature Id="FT_SampleScripts" Title="Sample Scripts" AllowAdvertise="no" Description="Sample scripts to show basic usage">
7570
<ComponentGroupRef Id="CG_SampleScripts" />

installer/buildInstaller.bat

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,22 @@ if NOT [%ERRORLEVEL%]==[0] (
133133
)
134134

135135
echo Compiling Unit test WiX source
136-
candle %INST_TEMP_DIR%\unittests.wxs -o %INST_TEMP_DIR%\unittests.wixobj -dunittestSource=..\pythonscript\python_tests
136+
candle %INST_TEMP_DIR%\unittests.wxs -o %INST_TEMP_DIR%\unittests.wixobj -dunittestSource=..\PythonScript\python_tests
137137
if NOT [%ERRORLEVEL%]==[0] (
138138
goto error
139139
)
140140

141+
echo Generating WiX information for ..\docs\build\html
142+
heat dir ..\docs\build\html -ag -cg CG_HtmlDocs -dr D_PythonScript -var var.htmldocsSource -t changeDirHtmlDoc.xsl -o %INST_TEMP_DIR%\htmldoc.wxs
143+
if NOT [%ERRORLEVEL%]==[0] (
144+
goto error
145+
)
141146

147+
echo Compiling Html doc WiX source
148+
candle %INST_TEMP_DIR%\htmldoc.wxs -o %INST_TEMP_DIR%\htmldoc.wixobj -dhtmldocsSource=..\docs\build\html
149+
if NOT [%ERRORLEVEL%]==[0] (
150+
goto error
151+
)
142152

143153
echo Compiling main PythonScript installer
144154
candle pythonscript.wxs -o %INST_TEMP_DIR%\pythonscript.wixobj -dversion=%PYTHONSCRIPTVERSION% -dbaseDir=.. -dpythonDir=%PYTHONBUILDDIR% -dvariantDir=%PYTHONSCRIPTDLLDIR%
@@ -153,7 +163,7 @@ IF NOT EXIST "build\%PYTHONSCRIPTVERSION%" (
153163
)
154164

155165

156-
light %INST_TEMP_DIR%\pythonscript.wixobj %INST_TEMP_DIR%\fullLib.wixobj %INST_TEMP_DIR%\extra.wixobj %INST_TEMP_DIR%\unittests.wixobj %INST_TEMP_DIR%\tcl.wixobj %INST_TEMP_DIR%\sampleScripts.wixobj -o build\%PYTHONSCRIPTVERSION%\PythonScript_%PYTHONSCRIPTVERSION%%NAME_ADDON%.msi -ext WixUIExtension
166+
light %INST_TEMP_DIR%\pythonscript.wixobj %INST_TEMP_DIR%\fullLib.wixobj %INST_TEMP_DIR%\extra.wixobj %INST_TEMP_DIR%\unittests.wixobj %INST_TEMP_DIR%\tcl.wixobj %INST_TEMP_DIR%\sampleScripts.wixobj %INST_TEMP_DIR%\htmldoc.wixobj -o build\%PYTHONSCRIPTVERSION%\PythonScript_%PYTHONSCRIPTVERSION%%NAME_ADDON%.msi -ext WixUIExtension
157167
if NOT [%ERRORLEVEL%]==[0] (
158168
goto error
159169
)

installer/buildReleaseZips.bat

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ copy ..\%PYTHONSCRIPTDLLDIR%\release\PythonScript.dll %INST_TEMP_DIR%\release\Fu
8383
copy ..\%PYTHONSCRIPTDLLDIR%\release\PythonScript.dll %INST_TEMP_DIR%\release\min\plugins
8484

8585
echo Copying Help
86-
xcopy /s /q ..\docs\build\singlehtml\*.* %INST_TEMP_DIR%\release\full\plugins\doc\PythonScript
87-
xcopy /s /q ..\docs\build\singlehtml\*.* %INST_TEMP_DIR%\release\min\plugins\doc\PythonScript
86+
xcopy /s /q ..\docs\build\html\*.* %INST_TEMP_DIR%\release\full\plugins\doc\PythonScript
87+
xcopy /s /q ..\docs\build\html\*.* %INST_TEMP_DIR%\release\min\plugins\doc\PythonScript
8888

8989
echo Copying Scripts
9090
xcopy /s /q ..\scripts\*.* %INST_TEMP_DIR%\release\full\plugins\PythonScript\scripts

installer/changeDirHtmlDoc.xsl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:wix="http://schemas.microsoft.com/wix/2006/wi" version="1.0">
2+
3+
<xsl:output method="xml" indent="yes" />
4+
<xsl:param name="realDirectoryId" select="'D_DocPythonScript'" />
5+
<xsl:include href="fixDirectoryAndFileRefs.xsl" />
6+
7+
</xsl:stylesheet>

0 commit comments

Comments
 (0)