rolf-thomas/ddev-project-menu
Composer 安装命令:
composer require rolf-thomas/ddev-project-menu
包简介
Interactive TUI menu for DDEV projects to run shell scripts from the terminal
README 文档
README
An interactive TUI (terminal UI) menu for DDEV projects. Run ddev project inside any DDEV project to get a keyboard-navigable menu of your shell scripts.
Features
- Scans
private/scripts/*.shfor annotated shell scripts - Groups scripts with a two-column layout: menu list on the left, help panel on the right
- Displays the DDEV project name as a Figlet title
- Confirmation prompt support before executing sensitive scripts
- No external TUI framework required at runtime — pure ANSI escape sequences
Requirements
- PHP 8.1+
- DDEV
Installation
Add this package as a dev dependency to your DDEV project:
composer require --dev rolf-thomas/ddev-project-menu
Then create the DDEV custom command file at .ddev/commands/host/project:
#!/usr/bin/env bash ## Description: Open the interactive project menu ## Usage: project ## Example: ddev project "$(composer -d "$DDEV_APPROOT" config vendor-dir)/rolf-thomas/ddev-project-menu/bin/ddev-project-menu"
Make it executable:
chmod +x .ddev/commands/host/project
The command runs on the host (not inside the container) — this is required for interactive TTY support.
Usage
ddev project
Navigate with arrow keys, press Enter to run the selected script, q or Esc to quit.
Script annotations
Scripts are included in the menu only if they have a @label annotation. All tags are read from the leading comment block (stops at the first non-comment line):
#!/usr/bin/env bash # @label Deploy to staging # @description Builds assets and syncs files to the staging server. # Runs composer install on the remote as well. # @confirm true # @group Deployment
| Tag | Required | Description |
|---|---|---|
@label |
yes | Short label shown in the menu list |
@description |
no | Help text shown in the right panel (multiple lines supported) |
@group |
no | Group heading; defaults to Sonstige |
@confirm |
no | Set to true to ask for confirmation before executing |
Scripts without @label are silently skipped — useful for helper files like functions.sh or ask.sh that are sourced by other scripts.
Local development
Clone the repository and install dependencies:
composer install
To test against a real DDEV project, add this package as a path repository in the host project's composer.json:
"repositories": { "ddev-project-menu": { "type": "path", "url": "/path/to/ddev-project-menu", "options": { "symlink": true } } }
Then run ddev project in that project to test the full TUI interactively.
License
MIT
rolf-thomas/ddev-project-menu 适用场景与选型建议
rolf-thomas/ddev-project-menu 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 3 次下载、GitHub Stars 达 0, 最近一次更新时间为 2026 年 05 月 04 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 rolf-thomas/ddev-project-menu 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 rolf-thomas/ddev-project-menu 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 3
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 36
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2026-05-04