DeepHorus is an innovative tech media and intelligence platform focused on AI, blockchain, startups, and emerging technologies.
Published on

Show HN: Omasharp: Build Omarchy apps with C# and.NET

Authors
  • avatar
    Name
    DeepHorus
    Twitter

Omasharp, a new development framework, enables developers to build Omarchy applications using C# and QML while achieving startup speeds comparable to native C++ apps. Created by Luis Rudge, the tool provides a template that compiles C# code to native binaries paired with a lightweight Qt host, eliminating the need for the .NET runtime on end-user systems. The project targets Omarchy 4, a Linux distribution featuring the Hyprland window manager and Qt 6.7 or newer, and is not affiliated with Omarchy or Basecamp.

Omarchy, known for its minimal and efficient desktop environment, traditionally relies on C++ and qmake for application development. While suitable for small utilities, C++ can be cumbersome for apps with complex logic. Omasharp addresses this by leveraging C#’s rich ecosystem—including NuGet, async I/O, and memory safety—without incurring the typical performance penalties of managed languages. The framework compiles C# ahead-of-time to native code, resulting in fast startup and low memory usage.

Developers install the .NET SDK via omarchy pkg add dotnet-sdk and then install the Omasharp template with dotnet new install Omasharp.Templates. Creating a new app is as simple as dotnet new omarchy-app -n Tally. The generated project contains two editable files: Backend.cs for logic and Main.qml for the user interface. Running dotnet publish compiles the C# to native code and bundles it with a Qt host, producing a self-contained executable that runs on the Qt libraries already shipped with Omarchy.

A benchmark comparing Omarchy’s calculator, omacalc, with a C# port built using Omasharp showed similar startup times, based on medians of seven interleaved runs. Unlike typical .NET applications, Omasharp apps avoid slow startup and high memory consumption. The framework also supports panel applications via the --kind panel flag, which runs the C# backend in a separate process to prevent crashes from affecting the shell.

Omasharp apps automatically follow the current Omarchy theme and repaint instantly when the theme changes. QML bindings connect to theme properties such as theme.accent and theme.background, while C# code accesses the same colors through a Theme class with a Changed event. This ensures a consistent look and feel across the desktop environment.

Publishing an app with dotnet publish -t:Install installs it to ~/.local/bin and creates a launcher entry. For sharing, developers can push their project to GitHub and tag a release; the template’s release workflow attaches an install.sh script that lets users install the app with a single command, without sudo or .NET. Building requires the .NET SDK, qmake6, g++, and Qt 6, while published apps need only Qt.

Each Omasharp project includes an agent skill in .agents/skills/omasharp/ that coding agents can read to learn how to build, check, and install the app. Rudge provides instructions for agents to download and install a create-omasharp-app skill, enabling users to simply ask their agent to 'build me an Omarchy app' without needing to reference the repository. This integration aims to streamline AI-assisted development workflows.

Omasharp currently supports Linux x64 with Omarchy 4, Hyprland, and Qt 6.7 or newer. By offering a modern, safe language with native performance, it could encourage more sophisticated applications for the Omarchy ecosystem. As the project evolves, it may attract developers who prefer C# over C++ for building desktop tools. The framework’s focus on agent compatibility also signals a growing trend of AI-assisted coding in open-source development.