# AutoAddTranslationTool **Repository Path**: luyuzheng/AutoAddTranslationTool ## Basic Information - **Project Name**: AutoAddTranslationTool - **Description**: No description available - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2018-08-07 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 美妆相机 Android端翻译文本导入脚本 --- ## 1.环境需求 --- - **python3+** > Mac: brew install python3 - **xlrd(解析excel文件)** > pip install xlrd - **lxml(解析xml文件)** > pip install lxml ## 2.使用说明 --- 1.下载翻译excel表至本地 2.修改excel表,添加stringId和注释 | xxx(注释文字) | 简体 | 繁体 | | :----------------: | :----: | :----: | | id1 | xxx | xxx | | id2 | xxx | xxx | | id3 | xxx | xxx | 3.修改config.json配置文件 Json配置文件key的含义如下 ``` excel_file_path:excel文件路径 excel_sheet_name:需要导入的sheet名称 project_res_path:AS工程res目录路径 project_res_file_name:需要导入的XML资源文件名 language_map:语言和资源文件夹名的映射关系 ``` 4.确保配置文件和脚本文件在同一目录下后运行脚本 > python translation_tool.py