No description
- Dart 81.9%
- Python 7.2%
- HTML 6%
- Shell 4.1%
- Dockerfile 0.8%
| .github/workflows | ||
| deploy | ||
| docker | ||
| lib | ||
| scripts | ||
| test | ||
| web | ||
| .dockerignore | ||
| .gitignore | ||
| agent.md | ||
| analysis_options.yaml | ||
| Dockerfile | ||
| l10n.yaml | ||
| pubspec.lock | ||
| pubspec.yaml | ||
| README.md | ||
UniqueDing Kitchen
Flutter Web ordering app with markdown-driven menu/recommendations.
Key Directories
lib/: app UI and runtime config loaderweb/public/: editable markdown data source (menu.md,recommend.md)scripts/: runtime/ops scripts used by the app lifecycletools/branding/: one-off branding/logo generation helpersdocker/: container entrypoint scriptsdeploy/: deployment examples (docker-compose.example.yaml).github/workflows/: CI workflow for Docker publishing
Common Commands
- Local verify:
flutter analyze && flutter test - Build web:
flutter build web --wasm --no-source-maps --no-web-resources-cdn --no-wasm-dry-run - Generate recommendation markdown:
python3 scripts/generate_recommendation.py
Script vs Tooling
scripts/generate_recommendation.py: production-facing helper used by Docker startup/cron to refreshrecommend.mdtools/branding/generate_logo_candidates_v4.py: one-off logo candidate generator, not used by runtime or deploy flow
generate_recommendation.py path behavior:
PUBLIC_DIRcontrols base directory (supports relative path; default preferspublic, thenweb/public)- output defaults to
${PUBLIC_DIR}/recommend.md - can override output via
RECOMMEND_FILE - script writes to a temporary file first, then atomically replaces target
generate_recommendation.py menu source behavior:
MENU_SOURCE=localreads${PUBLIC_DIR}/menu.mdMENU_SOURCE=trilliumfetches and parsesTRILLIUM_URL(usesTRILLIUM_TITLE)- generated recommendation format is markdown table (
| 名称 | 描述 | 口味 | 小料 |)
generate_recommendation.py OpenAI env behavior:
- URL supports
OPENAI_BASE_URL/OPENAI_URL/API_URL/BASE_URL - API key supports
OPENAI_API_KEY/API_KEY - model supports
OPENAI_MODEL/MODEL - URL can be either base (for example
https://api.openai.com/v1) or full endpoint (for examplehttps://api.openai.com/v1/chat/completions)
Docker Compose Example
Use deploy/docker-compose.example.yaml as a template:
docker compose -f deploy/docker-compose.example.yaml up -d
If you host behind a reverse proxy subpath (for example /cook/), set:
WEB_BASE_HREF=/cook/
The value must start and end with /.
Trillium Menu Source
Runtime config supports switching menu source via env vars:
MENU_SOURCE:local(default) ortrilliumTRILLIUM_URL: HTML article URL, for examplehttps://note.uniqueding.xyz/share/cooklistTRILLIUM_TITLE: article title marker used to locate the content section, for examplecooklist
Recommend Scheduler
RECOMMEND_CRON_SCHEDULE: cron expression for daily recommendation generation, default0 0 * * *