-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cross-platform build using FAKE and Windows Installer with InnoSetup (#…
…25) * feat(setup): Initial installer using InnoSetup * feat(setup): allow unchecking of CLI * refactor: moved source code to src and added build project * feat: Complete Build * fix: move backup back (tests dont run though) * chore: remove old files * fix(build): skip tests * feat(build): parallelize build * chore: rename readme to README * docs(build): document build in CONTRIBUTE.md * ci: Use FAKE to build and test apps in workflows * fix(ci): explicitly restore newer version of MSBuild.StructuredLogger * fix(build): platform differences * ci/dist must be created before Archive and Vim are run But if the target platform is Linux, then they were run together * Linux executables do not have file extensions * fix(build): dummy stage to ensure staging is finished before distributing * fix(build): define Inno toolpath and defines * fix(setup): No hard-coded paths * fix(ci): explicitly pass version
- Loading branch information
1 parent
d28e1d1
commit 9a02800
Showing
122 changed files
with
399 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# Contributing | ||
|
||
Feel free to open issues and merge requests! | ||
|
||
## Building | ||
The app can be build with FAKE (F#'s make) using the command: | ||
`dotnet run --project src/TransactionQL.Build/TransactionQL.Build.fsproj` | ||
|
||
This command supports the following parameters: | ||
|
||
| Parameter | Description | | ||
|---------------------------|-------------| | ||
| `-e SkipTests=1` | Do not run the test suite | | ||
| `-e VERSION=1.0.0` | Set the version of the assemblies and apps | | ||
| `-e CONFIGURATION=DEBUG` | Compile the apps in Debug rather than Release | | ||
| `-e parallel-jobs=n` | Use `n` workers to run the build in parallel | | ||
| `-t <target>` | Run the specific target (e.g. `Test`) | | ||
|
||
The default target (`Complete`) runs the entire build and copies the | ||
artifacts to the `ci/dist` directory. | ||
|
||
### Artifacts | ||
One assembly per plugin. These assemblies are _not_ selfcontained and require | ||
cli or gui to load them. The cli and gui do contain their necessary | ||
dependencies. | ||
|
||
The cli is built as a single executable that is published as a single file, but | ||
not self contained. It still requires the .NET runtime to run. | ||
|
||
The gui is built as a single executable alongside a few DLLs required for rendering. | ||
It also requires the .NET runtime to run. | ||
|
||
### Supported Targets | ||
|
||
* **Clean:** Empties the `ci` directory to clean up after previous builds. | ||
* **Restore:** Restores dependencies for the entire solution. | ||
* **Test:** Runs all unit tests. | ||
* **Publish:** Ensures that the `ci/build` folder exists. | ||
* **Publish Plugins:** Builds and copies the plugin assemblies to `ci/build/plugins/`. | ||
* **Publish CLI:** Builds and copies the CLI executable to `ci/build/console/`. | ||
* **Publish GUI:** Builds and copies the GUI files to `ci/build/desktop/`. | ||
* **Stage Artifacts:** Builds and copies just the required application files to `ci/staging/`. | ||
* **Dist:** Ensures that the `ci/dist` folder exists. | ||
* **Setup:** (Windows only) Creates a installer using InnoSetup. | ||
* **Archive:** Bundles the application files into `ci/dist/tql-<platform>-x64.zip`. | ||
* **Vim:** Copies the vim syntax highlighting file to `ci/dist/tql.vim`. | ||
* **Complete:** Runs all of the above. | ||
|
||
## Conventions | ||
|
||
1. Code must be formatted using `dotnet format` before merging into `main`. |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"profiles": { | ||
"TransactionQL.Build": { | ||
"commandName": "Project", | ||
"commandLineArgs": "-e parallel-jobs=4" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<OutputType>Exe</OutputType> | ||
<TargetFramework>net8.0</TargetFramework> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<None Include="tql.vim" /> | ||
<None Include="tql.iss" /> | ||
<Compile Include="build.fs" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Fake.Core.Target" Version="6.1.1" /> | ||
<PackageReference Include="Fake.DotNet.Cli" Version="6.1.1" /> | ||
<PackageReference Include="Fake.Installer.InnoSetup" Version="6.1.1" /> | ||
<PackageReference Include="Fake.IO.Zip" Version="6.1.1" /> | ||
<PackageReference Include="MSBuild.StructuredLogger" Version="2.2.337" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Update="FSharp.Core" Version="8.0.400" /> | ||
</ItemGroup> | ||
|
||
</Project> |
Oops, something went wrong.