> For the complete documentation index, see [llms.txt](https://blankwallet.gitbook.io/fbce/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://blankwallet.gitbook.io/fbce/building-source-code.md).

# Building Source Code

In order to rebuild the source-code, .NET and C# knowledge is must! The `FBCE` project targets .NET Standard, and `FBCE.Desktop` targets .NET 5, so you need to [install .NET 5 SDK](https://dotnet.microsoft.com/download/dotnet/5.0) on your machine.

### Building using IDE

You can use Visual Studio 2019, JetBrains Ride. All you need to do is to open .sln file that is located inside `source-code` folder and build solution directly on the IDE.

The `FBCE.Desktop` project uses Avalonia to build *cross-platform* desktop app. You might want to [install Avalonia extension](https://marketplace.visualstudio.com/items?itemName=AvaloniaTeam.AvaloniaforVisualStudio) to make development much easier.

### Building using CLI

Navigate to `source-code` folder and execute bellow commands;

```bash
dotnet restore & dotnet build
```

The build files will be located inside `bin` folder.

### Publishing FBCE.Desktop

Navigate to `source-code → src → FBCE.Desktop` folder and execute:

```bash
dotnet publish -c Release -r win-x86 -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained & dotnet publish -c Release -r win-x64 -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained & dotnet publish -c Release -r linux-x64 -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained & dotnet publish -c Release -r osx-x64 -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained
```

This command will publish single file, self-contained desktop application for Windows (x64 and x86), macOS (x64) and Linux (x64).
