|
1 | | -# 🖥️ OWD CLI |
| 1 | +<p align="center"> |
| 2 | + <img width="160" height="160" src="https://avatars.githubusercontent.com/u/65117737?s=160&v=4" /> |
| 3 | +</p> |
| 4 | +<h1 align="center">CLI</h1> |
| 5 | +<h3 align="center"> |
| 6 | + Control Panel and Command Line Interface for Open Web Desktop. |
| 7 | +</h3> |
2 | 8 |
|
3 | | -> Control Panel and Command Line Interface for Open Web Desktop |
| 9 | +<br /> |
4 | 10 |
|
5 | | -This package provides the \`desktop\` and \`owd\` commands to manage your Open Web Desktop workspace, applications, and themes. |
| 11 | +## Overview |
6 | 12 |
|
7 | | -## Features |
8 | | - |
9 | | -- **Control Panel**: A powerful TUI (Terminal User Interface) to manage your desktop state. |
10 | | -- **Package Management**: Install, update, and remove apps, themes, and modules. |
11 | | -- **Scaffolding**: Generate new applications and themes from blueprints. |
12 | | -- **Sync**: Keep your \`package.json\` and \`desktop.config.ts\` in sync. |
| 13 | +This package provides the official `desktop` (and legacy `owd`) CLI tool for Open Web Desktop. It features a rich Terminal User Interface (TUI) Control Panel to manage your running local OWD dev server, install/remove apps, modules, and themes, configure workspace settings, and scaffold new OWD components. |
13 | 14 |
|
14 | 15 | ## Installation |
15 | 16 |
|
16 | | -\`\`\`bash |
17 | | -pnpm add -D @owdproject/cli |
18 | | -\`\`\` |
| 17 | +```bash |
| 18 | +pnpm add -g @owdproject/cli |
| 19 | +``` |
| 20 | +*Note: You can also install it as a devDependency in your OWD workspace project and run it via `pnpm desktop`.* |
| 21 | + |
| 22 | +## Features |
| 23 | + |
| 24 | +- **Control Panel (TUI)**: An interactive terminal interface for managing OWD projects. |
| 25 | +- **Scaffolding**: Instantly initialize new workspaces or scaffold new apps and themes. |
| 26 | +- **Package Management**: Install and validate OWD modules from npm, local directories, or custom Git repositories. |
| 27 | +- **Graceful Fallback**: The interactive Control Panel compiles a fast Go-based TUI locally, falling back seamlessly to a JavaScript runner if Go is not available. |
19 | 28 |
|
20 | 29 | ## Usage |
21 | 30 |
|
22 | | -\`\`\`bash |
23 | | -pnpm desktop |
24 | | -\`\`\` |
| 31 | +Once installed, run the `desktop` command to open the control panel: |
| 32 | + |
| 33 | +```bash |
| 34 | +desktop |
| 35 | +``` |
| 36 | + |
| 37 | +### CLI Reference |
| 38 | + |
| 39 | +#### Dev Server |
| 40 | +Start the development server for the monorepo or automatically detect a module's playground: |
| 41 | +```bash |
| 42 | +desktop dev [--playground] |
| 43 | +``` |
| 44 | + |
| 45 | +#### Add Packages |
| 46 | +Install apps, modules, or themes from npm, local directories, or custom repositories: |
| 47 | +```bash |
| 48 | +desktop add app-todo --npm |
| 49 | +desktop add theme-nova --dev |
| 50 | +desktop add module-fs --from <github-user> |
| 51 | +``` |
| 52 | + |
| 53 | +#### Scaffold a Project |
| 54 | +Initialize a fresh OWD workspace: |
| 55 | +```bash |
| 56 | +desktop init [project-name] |
| 57 | +``` |
| 58 | + |
| 59 | +#### Validation |
| 60 | +Check Nuxt module configuration and playground directory structures: |
| 61 | +```bash |
| 62 | +desktop validate |
| 63 | +``` |
25 | 64 |
|
26 | | ---- |
| 65 | +## License |
27 | 66 |
|
28 | | -Licensed under [MIT](./LICENSE) |
| 67 | +This package is released under the [MIT License](LICENSE). |
0 commit comments