ivy-interactive/ivy-framework/ivy-deploy-to-desktop
Claude Code and agent skill by ivy-interactive/ivy-framework
- community
Checking that the SKILL.md file is still in the repository.
Deploy an Ivy project as a standalone desktop application. Use when the user asks to publish, deploy, package, or export their Ivy app as a desktop app, native app, executable, or .exe. Scaffolds a desktop wrapper project using Ivy.Desktop, generates a Program.cs, publishes with dotnet, and copies the executable to the user's desktop.
Install
npx vskill@latest install ivy-interactive/ivy-framework/ivy-deploy-to-desktopSKILL.md
ivy-deploy-to-desktop
Deploy an Ivy project as a standalone desktop application using Ivy.Desktop.
Pre-flight: Read Learnings
If the file .ivy/learnings/ivy-deploy-to-desktop.md exists in the project directory, read it first and apply any lessons learned from previous runs of this skill.
Reference Files
Read before implementing:
- references/AGENTS.md -- Ivy framework API reference (widgets, hooks, layouts, inputs, colors)
Workflow
- Verify the project -- Confirm the working directory is a valid Ivy project and that it builds successfully with
dotnet build. If it does not build, stop and ask the user to fix build errors first.
- Determine the project namespace -- Find the root namespace from the
.csprojfile or existing source files.
- Scaffold the desktop project -- Create a desktop wrapper project under
.ivy/publish/[Namespace].Desktop/. This is a separate .NET project that references the main Ivy project and adds the Ivy.Desktop package.
- Generate Program.cs -- Write a
Program.csfor the desktop wrapper following the rules in the generation guide below.
- Publish the application -- Run
dotnet publish -c Releaseon the desktop project to produce a self-contained executable.
- Copy to desktop -- Place the published executable on the user's desktop so it is ready to run.
Step 4: Generating Program.cs
Write a Program.cs for the desktop project ([Namespace].Desktop) at .ivy/publish/[Namespace].Desktop/Program.cs.
Before generating, read the original web project's Program.cs and list the files in the project's Apps/ directory.
The generated Program.cs must:
- Use
IvyandIvy.Desktopnamespaces. - Create a
new Server(new ServerArgs { Silent = true }). - Assembly references -- For
AddAppsFromAssemblyandAddConnectionsFromAssembly, you MUST pass an explicit assembly reference because the entry assembly in the desktop project is different from the main app assembly. Find a class from the original project (e.g., an[App]class) and usetypeof(ThatClass).Assemblyas the argument:
``csharp var targetAssembly = typeof(MyNamespace.Apps.SomeAppClass).Assembly; server.AddAppsFromAssembly(targetAssembly); server.AddConnectionsFromAssembly(targetAssembly); ``
- Preserve any other service registrations from the original (e.g.
server.UseCulture(...), anyserver.Add*calls). - Chrome handling:
- Count the number of apps in the
Apps/directory. - If there are multiple apps, preserve the chrome configuration (e.g.
UseAppShell) in the desktop version so users can navigate between apps via the sidebar. - If there is only a single app, do NOT add
UseAppShell. Useserver.UseDefaultApp(typeof(TheApp))instead. Single-app desktop applications should not have a sidebar.
- Window sizing -- Choose appropriate
.Size(width, height)values for theDesktopWindowbased on the apps found inApps/:
- Multi-app projects with chrome/sidebar:
1280, 800or larger - Single-app dashboards or data-heavy apps:
1200, 800 - Single-app form/tool apps (calculators, converters, simple utilities):
800, 600 - Single-app narrow/focused apps (chat, single-column):
500, 700 - When unsure, default to
1024, 768
- Replace the web server startup with:
``csharp return new DesktopWindow(server) .Title("[AppTitle]") .Size(WIDTH, HEIGHT) // Use the dimensions chosen in step 6 .Run(); ``
- Do NOT include any web host building,
app.Run(),builder.Build(), Kestrel, or HTTP pipeline code.
CRITICAL: Write ONLY to .ivy/publish/[Namespace].Desktop/Program.cs. Do NOT create any files in the main project directory. Do NOT create a .Desktop subfolder in the main project. The desktop project lives under .ivy/publish/[Namespace].Desktop/ -- all desktop files must go there.
Output ONLY raw C# code, no markdown fences or explanation.
Troubleshooting
If the publish step fails:
- Ensure the project builds successfully with
dotnet build. - Check that the Ivy.Desktop NuGet package is available.
- Verify you have the .NET 10 SDK installed.
- If the error mentions "Ambiguous project name", create a
Directory.Build.propsin the desktop project directory with content<Project></Project>to isolate the project from the parent directory tree.
Recovery Steps
- Diagnose using the troubleshooting steps above to identify the root cause.
- After fixing the underlying issue, choose ONE of these approaches:
Option A: Retry from scratch (recommended for transient failures like NuGet package issues or temporary build failures) -- re-run the full workflow from step 1.
Option B: Manual desktop publish (recommended for persistent workflow failures):
- Run
dotnet publish -c Release -r <rid>(e.g.,-r win-x64,-r osx-arm64,-r linux-x64) - Locate the published executable in
bin/Release/net10.0/{rid}/publish/ - Copy the executable to the user's desktop (see "Desktop Copy" below)
Use ivy docs to find deployment patterns: "How do I publish an Ivy app as a desktop application?"
- Do NOT skip the desktop copy step -- the executable must be accessible on the desktop for the user.
Desktop Copy
If you recover manually, you MUST copy the published executable to the user's desktop:
- Publish location:
bin/Release/net10.0/{rid}/publish/ - Desktop folder: Use the system desktop path (e.g.,
C:\Users\{user}\Desktop\) - Copy the
.exefile (Windows) or the binary (macOS/Linux) to the desktop
Completion
When the publish succeeds, inform the user:
- The application name
- The output location (on their desktop)
- That it is ready to run
Post-run: Evaluate and Improve
After completing the task:
- Evaluate: Did the build succeed? Were there compilation errors, unexpected behavior, or manual corrections needed during this run?
- Update learnings: If anything required correction or was surprising, append a concise entry to
.ivy/learnings/ivy-deploy-to-desktop.md(create the file and.ivy/learnings/directory if they don't exist). Each entry should note: the date, what went wrong, why, and what to do differently next time. - Skip if clean: If everything succeeded without issues, do not update the learnings file.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingsrc/claude-plugin/skills/ivy-deploy-to-desktop/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/ivy-interactive/ivy-framework/ivy-deploy-to-desktop)