INNER CODE UNIT · Python
inject_panel
1186258278/OpenClawChineseTranslation · scripts/inject_panel.py:190
def inject_panel():
"""注入功能面板到所有 Dashboard 构建产物"""
print("🦞 OpenClaw 功能面板注入")
print("=" * 50)
print(f"📍 当前工作目录: {os.getcwd()}")
# 查找所有 Dashboard 目录
dashboard_dirs = find_all_dashboard_dirs()
if not dashboard_dirs:
print("\n❌ 找不到任何 Dashboard 目录!")
print(f" 脚本目录: {SCRIPT_DIR}")
print(f" ROOT_DIR: {ROOT_DIR}")
# 列出目录结构帮助调试
if os.path.exists('openclaw/dist'):
print("\n📁 openclaw/dist/ 目录内容:")
for item in os.listdir('openclaw/dist'):