feat(desktop): embed CLI in app and PATH install (#13669)

*  feat(desktop): embed CLI in app and PATH install

Made-with: Cursor

*  feat(desktop): add CLI command execution feature and UI integration

- Implemented `runCliCommand` method in `ElectronSystemService` to execute CLI commands.
- Added `CliTestSection` component for testing CLI commands within the app.
- Updated `SystemCtr` to include CLI command execution functionality.
- Enhanced `generateCliWrapper` to create short aliases for CLI commands.
- Integrated CLI testing UI in the system tools settings page.

Signed-off-by: Innei <tukon479@gmail.com>

*  feat: enhance working directory handling for desktop

- Updated working directory logic to prioritize topic-level settings over agent-level.
- Introduced local storage management for agent working directories.
- Modified tests to reflect changes in working directory behavior.
- Added checks to ensure working directory retrieval is only performed on desktop environments.

Signed-off-by: Innei <tukon479@gmail.com>

*  feat(desktop): implement CLI command routing and cleanup

- Introduced `CliCtr` for executing CLI commands, enhancing the desktop application with CLI capabilities.
- Updated `ShellCommandCtr` to route specific commands to `CliCtr`, improving command handling.
- Removed legacy CLI path installation methods from `SystemCtr` and related services.
- Cleaned up localization files by removing obsolete entries related to CLI path installation.

Signed-off-by: Innei <tukon479@gmail.com>

* 🚸 settings(system-tools): show CLI embedded test only in dev mode

Made-with: Cursor

---------

Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
Innei
2026-04-09 00:53:49 +08:00
committed by GitHub
parent eebf9cb056
commit e65e2c3628
53 changed files with 1379 additions and 168 deletions
+4
View File
@@ -140,5 +140,9 @@ pnpm-lock.yaml
.turbo
spaHtmlTemplates.ts
# Embedded CLI bundle (built at pack time)
apps/desktop/resources/bin/lobe-cli.js
apps/desktop/resources/cli-package.json
.superpowers/
docs/superpowers