A WiX based installer for Groovy. Binaries are available on JFrog.
- msbuild (from Visual Studio 2022, Build Tools for Visual Studio, or JetBrains Rider)
- WiX Toolset
-
Run the commands below
New-Item -Path "apache-groovy-binary" -ItemType Directory Expand-Archive -Path "apache-groovy-binary-*.zip" -DestinationPath . Move-Item -Path "groovy-*\*" -Destination "apache-groovy-binary" New-Item -Path "apache-groovy-docs" -ItemType Directory Expand-Archive -Path "apache-groovy-docs-*.zip" -DestinationPath . Move-Item -Path "groovy-*\*" -Destination "apache-groovy-docs"
-
Replace
x.y.zwith the Groovy version in groovy-wix.wixproj (this can be edited in Visual Studio by editing the Output name on the Installer tab, and the Define preprocessor variables on the _Build tab in the properties of the groovy-wix WIX project). The result will be something likediff --git a/groovy-wix/groovy-wix.wixproj b/groovy-wix/groovy-wix.wixproj index 070304a..8c602d0 100644 --- a/groovy-wix/groovy-wix.wixproj +++ b/groovy-wix/groovy-wix.wixproj @@ -3,8 +3,8 @@ <EnableDefaultCompileItems>false</EnableDefaultCompileItems> </PropertyGroup> <PropertyGroup> - <OutputName>groovy-x.y.z</OutputName> - <DefineConstants>groovyVersion=x.y.z;binariesSourceFolder=$(SolutionDir)apache-groovy-binary;docsSourceFolder=$(SolutionDir)apache-groovy-docs</DefineConstants> + <OutputName>groovy-5.0.0</OutputName> + <DefineConstants>groovyVersion=5.0.0;binariesSourceFolder=$(SolutionDir)apache-groovy-binary;docsSourceFolder=$(SolutionDir)apache-groovy-docs</DefineConstants> <WixVariables> </WixVariables> </PropertyGroup>
-
Build the solution using one of the commands below (depending on how you installed
msbuild)& "C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\MSBuild.exe" groovy-wix.slnx /t:Build /p:Configuration=Release /p:Platform=x86 & "C:\Program Files (x86)\Microsoft Visual Studio\18\BuildTools\MSBuild\Current\Bin\MSBuild.exe" groovy-wix.slnx /t:Build /p:Configuration=Release /p:Platform=x86 $env:LOCALAPPDATAPrograms\Rider\tools\MSBuild\Current\Bin\MSBuild.exe groovy-wix.slnx /t:Build /p:Configuration=Release /p:Platform=x86
-
Upload the new installer to Groovy JFrog. The MSI should be put in a new directory, with the name of the release version.
Reset the project by cleaning the solution using one of the commands below (depending on how you installed msbuild)
& "C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\MSBuild.exe" groovy-wix.slnx /t:Clean /p:Configuration=Release /p:Platform=x86
& "C:\Program Files (x86)\Microsoft Visual Studio\18\BuildTools\MSBuild\Current\Bin\MSBuild.exe" groovy-wix.slnx /t:Clean /p:Configuration=Release /p:Platform=x86
$env:LOCALAPPDATAPrograms\Rider\tools\MSBuild\Current\Bin\MSBuild.exe groovy-wix.slnx /t:Clean /p:Configuration=Release /p:Platform=x86Then run these commands
Remove-Item -Path "apache-groovy-binary", "apache-groovy-docs" -Recurse -Force
git checkout groovy-wix/groovy-wix.wixproj groovy-wix/GroovyBinaries.wsx groovy-wix/GroovyDocs.wsx