tdf-tools


Nametdf-tools JSON
Version 2.1.3 PyPI version JSON
download
home_pagehttps://git.2dfire.net/app/flutter/tools/package_tools
Summary二维火 flutter 脚手架工具
upload_time2023-01-17 06:56:16
maintainer
docs_urlNone
authorJian Xu
requires_python>=3.9.0,<4.0.0
licenseMIT
keywords tdf tdf-tools tdf_tools
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ## 帮助文档

```shell
NAME
    tdf_tools - 二维火 Flutter 脚手架工具,包含项目构建,依赖分析,git等功能。。

SYNOPSIS
    tdf_tools GROUP | COMMAND

DESCRIPTION
    二维火 Flutter 脚手架工具,包含项目构建,依赖分析,git等功能。。

GROUPS
    GROUP is one of the following:

     module
       模块相关工具: tdf_tools module -h 查看详情

     package
       封包工具相关:tdf_tools package -h 查看详情

     translate
       国际化相关:tdf_tools translate -h 查看详情

COMMANDS
    COMMAND is one of the following:

     git
       tdf_tools git【git 命令】:批量操作 git 命令, 例如 tdf_tools git push

     router
       tdf_tools router:会以交互式进行路由操作,对指定的模块执行路由生成和路由注册逻辑

     upgrade
       tdf_tools upgrade:升级插件到最新版本
        
```



## 插件安装方式

安装python包

```
pip3 install tdf-tools --user
```

安装并更新python包

```
pip3 install --upgrade tdf-tools --user
```

安装测试环境python包

```
pip3 install -i https://test.pypi.org/simple/ tdf-tools --user
```

安装并更新测试环境python包

```
pip3 install --upgrade -i https://test.pypi.org/simple/ tdf-tools --user
```



## 工具使用流程说明

### 1.准备工作

- 确保python的bin插件目录已经被配置到环境变量中(这一步不满足的话,插件安装之后是无法识别到本插件命令的)

- 在~目录下,创建.tdf_tools_config文件并配置相关必需属性如下

```json
git_private_token=***
```

git_private_token是gitlab的token

获取途径:进入gitlab页面,点击右上角头像,选择Preferences,选择左侧列表中的AccessToken进行创建

**上述步骤如果没有做,会在使用插件时,会有提示**

### 2.初始化

#### i.进入壳目录(确保执行命令在壳目录内)

#### ii.执行tdf_tools module init

- 判断当前目录是否存在tdf_cache,若不存在,则会自动创建tdf_cache
- 自动读取当前壳模块名称,写入initial_config.json配置文件;
- 读取当前壳分支,写入initial_config.json配置文件;
- 交互式提示用户输入需要开发的模块名并写入initial_config.json配置文件的moduleNameList列表字段中
- !退出,即输入完成
- 自动clone所有开发模块到  ```../.tdf_flutter```  隐藏目录中;
- 将所有开发模块分支切换至与壳一致;
- 自动分析依赖树,并**由下至上**对所有模块自动执行```flutter pub upgrade```;

#### iii.开发过程中

##### 1.开发模块添加

- 若是有新模块需要添加入开发模块中,可直接修改initial_config.json配置文件,修改moduleNameList字段;
- 执行tdf_tools deps更新依赖

##### 2.新开发模块添加

- 添加新模块后,会提示找不到模块,实际查找的是```tdf_cache```文件夹中的module_config.json文件;
- 如果没有找到该模块,则可以执行```tdf_tools module-update```,更新远程module_config.json文件;
- 删掉本地的module_config.json文件,重新执行命令即可,脚本会自动判断本地是否存在该配置文件,如果不存在会**下载**;

<span style="color:#ff0000">请确保gitlab仓库的新开发模块master分支是一个flutter模块,如果判定不是flutter模块,则会报错(判定条件为存在pubspec.yaml文件)</span>



### 3.版本控制

版本控制请使用tdf_tools命令,命令详情可使用  ```tdf_tools -h```  查看,现已支持大部分命令,若有特殊命令需要执行,可以使用  ```tdf_tools <git命令>``` ,如:```tdf_tools git add .```



### 4.自动打包发布

暂未接入打包工具,预计下一季度进行支持;



**<span style="color:#ff0000">FAQ</span>**

windows系统请使用bash命令;



## 额外功能说明

### 1.二维数组表达依赖树

生成一个二维数组,可根据该二维数组的数据进行**并发**打tag,每一层的模块,都可以同时进行打tag发布操作,减少发布耗时;

```json
[
	["tdf_channel", "tdf_event", "tdf_network"], 
	["tdf_widgets"], 
	["tdf_smart_devices", "tdf_account_module"], 
	["flutter_reset_module"]
]
```

如上数据,数组中每一个节点中的模块均可同时打tag,节点之间需要由上至下的顺序进行tag操作



### 2.插件更新

执行 ```tdf_tools upgrade```



### 3.远程模块配置文件更新

执行 ```tdf_tools module module_update```



## 依赖树分析原理

采用有向有/无环图进行依赖树的分析

数据结构采用如下:

```python
class DependencyNode:
    def __init__(self):
        self.nodeName = ''
        self.parent = []  # 父亲节点列表
        self.children = []  # 子孙节点列表
        self.delete = False
```

![dependency](./README_DIR/dependency.png)

如上图1:一个正常的依赖树表示;

如上图2:对图1中,依赖树所有节点去重,变换为图2有向图;	



**分析流程:**

**依赖图构建**

```python
# 生成依赖图
    def _generateDependenciesMap(self):
        for package in self.__moduleDependenciesMap:
            for module in moduleNameList:
                if package == module:
                    # 到这一步表明当前这个模块属于开发模块且在当前模块的依赖模块列表中,是当前模块的子模块
                    self._mNodeDict[self.__moduleName].children.append(package)
                    self._mNodeDict[package].parent.append(self.__moduleName)
```

- 共5个节点

  - node构建:

    - ```python
      {
      	"模块1":{
          "nodeNmae": "模块1",
          "parent": [],
          "children": ["模块2","模块3","模块4","模块5"],
          "delete": False
      	},
      	"模块2":{
          "nodeNmae": "模块2",
          "parent": ["模块1"],
          "children": ["模块4","模块5"],
          "delete": False
      	}
      	"模块3":{
          "nodeNmae": "模块3",
          "parent": ["模块1"],
          "children": ["模块5"],
          "delete": False
      	}
      	"模块4":{
          "nodeNmae": "模块4",
          "parent": ["模块1","模块2"],
          "children": [],
          "delete": False
      	}
      	"模块5":{
          "nodeNmae": "模块5",
          "parent": ["模块1","模块2","模块3"],
          "children": [],
          "delete": False
      	}
      }
      ```

**依赖图解析伪代码(以一维数组为例)**

```python
# 返回二维数组,用于并发打tag
    def _generateDependenciesOrder(self):
        resList = []
        while 存在节点delete属性不为True:
            
            for:查找子节点为0的节点
            	设置节点delete属性为True
              
            for:deleteItemList = 拿到所有delete属性为true的节点

            for:遍历所有节点,如果节点的子节点中包含deleteItemList的节点,则将其从子节点列表中删除
```





- **initial_config.json文件说明**

  ```json
  {
      "featureBranch": "feature/test_dev_1", // 开发分支
      "shellName": "flutter_reset_module",
      // 项目需要开发的模块,可自由配置
      "moduleNameList": [
          "flutter_reset_module",
          "tdf_smart_devices",
          "tdf_widgets",
          "tdf_channel"
      ]
  }
  ```

- **module_config.json文件说明**

  ```json
  {
      "flutter_globalyun_us_module": {
        	"id": "11111"
          "type": "shell",
          "git": "git@git.2dfire.net:app/flutter/app/flutter_globalyun_us_module.git"
      },
      "tdf_router_anno": {
          "type": "base",
          "git": "git@git.2dfire.net:app/flutter/app/tdf_router_anno.git"
      },
  }
  //语意
  {
    "模块名":{
      "id": 项目gitlab id
      "类型": gitlab group名
      "git": gitlab地址
    }
  }
  ```



## 后续计划

<span style="color:#ff0000">**问题:**</span>由于现在flutter ci 【lint】【tag】任务脚本成功率过于低,很多时候是因为项目模块的配置问题导致的,且后续会接入一键打tag工具

方案:在执行统一push前,对所有模块的项目配置信息进行校验,确保数据规范;



## 插件打包发布命令

**插件打包命令**

```
poetry build
```
**插件发布命令**

```
poetry publish
```

## History

### 2.1.00

- 路由功能支持flutter版本3.3.10,兼容flutter版本2.2.3;

### 2.0.61

- Flutter国际化字符串整合;

### 2.0.38

- 路由生成完后增加路由相关代码format(解决windows代码生成后顺序错乱);

### 2.0.01

- Cli 框架升级;
- 代码重构;

### **1.1.00(2022-4-28)**

- 国际化解决输出json中包含转义字符的问题,如\n;
- 四类语言输出文件自动格式化

### **1.0.55(2022-4-28)**

- 国际化key使用中文(依照ios项目开发形式);

### **1.0.53(2022-4-28)**

- 国际化流程中,兼容解决部分json解析失败问题,譬如字符串中包含"="符号;

> 错误日志如:Unterminated string starting at: line 1 column 5650 (char 5649)

### **1.0.50(2022-4-28)**

- 国际化增加繁体字翻译;


            

Raw data

            {
    "_id": null,
    "home_page": "https://git.2dfire.net/app/flutter/tools/package_tools",
    "name": "tdf-tools",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.9.0,<4.0.0",
    "maintainer_email": "",
    "keywords": "tdf,tdf-tools,tdf_tools",
    "author": "Jian Xu",
    "author_email": "17826875951@163.com",
    "download_url": "https://files.pythonhosted.org/packages/91/d0/2fe77748076c29cfbca5301663364da3bcb8f7680b602e1cd763b3da6ae2/tdf_tools-2.1.3.tar.gz",
    "platform": null,
    "description": "## \u5e2e\u52a9\u6587\u6863\n\n```shell\nNAME\n    tdf_tools - \u4e8c\u7ef4\u706b Flutter \u811a\u624b\u67b6\u5de5\u5177\uff0c\u5305\u542b\u9879\u76ee\u6784\u5efa\uff0c\u4f9d\u8d56\u5206\u6790\uff0cgit\u7b49\u529f\u80fd\u3002\u3002\n\nSYNOPSIS\n    tdf_tools GROUP | COMMAND\n\nDESCRIPTION\n    \u4e8c\u7ef4\u706b Flutter \u811a\u624b\u67b6\u5de5\u5177\uff0c\u5305\u542b\u9879\u76ee\u6784\u5efa\uff0c\u4f9d\u8d56\u5206\u6790\uff0cgit\u7b49\u529f\u80fd\u3002\u3002\n\nGROUPS\n    GROUP is one of the following:\n\n     module\n       \u6a21\u5757\u76f8\u5173\u5de5\u5177\uff1a tdf_tools module -h \u67e5\u770b\u8be6\u60c5\n\n     package\n       \u5c01\u5305\u5de5\u5177\u76f8\u5173\uff1atdf_tools package -h \u67e5\u770b\u8be6\u60c5\n\n     translate\n       \u56fd\u9645\u5316\u76f8\u5173\uff1atdf_tools translate -h \u67e5\u770b\u8be6\u60c5\n\nCOMMANDS\n    COMMAND is one of the following:\n\n     git\n       tdf_tools git\u3010git \u547d\u4ee4\u3011\uff1a\u6279\u91cf\u64cd\u4f5c git \u547d\u4ee4, \u4f8b\u5982 tdf_tools git push\n\n     router\n       tdf_tools router\uff1a\u4f1a\u4ee5\u4ea4\u4e92\u5f0f\u8fdb\u884c\u8def\u7531\u64cd\u4f5c\uff0c\u5bf9\u6307\u5b9a\u7684\u6a21\u5757\u6267\u884c\u8def\u7531\u751f\u6210\u548c\u8def\u7531\u6ce8\u518c\u903b\u8f91\n\n     upgrade\n       tdf_tools upgrade\uff1a\u5347\u7ea7\u63d2\u4ef6\u5230\u6700\u65b0\u7248\u672c\n        \n```\n\n\n\n## \u63d2\u4ef6\u5b89\u88c5\u65b9\u5f0f\n\n\u5b89\u88c5python\u5305\n\n```\npip3 install tdf-tools --user\n```\n\n\u5b89\u88c5\u5e76\u66f4\u65b0python\u5305\n\n```\npip3 install --upgrade tdf-tools --user\n```\n\n\u5b89\u88c5\u6d4b\u8bd5\u73af\u5883python\u5305\n\n```\npip3 install -i https://test.pypi.org/simple/ tdf-tools --user\n```\n\n\u5b89\u88c5\u5e76\u66f4\u65b0\u6d4b\u8bd5\u73af\u5883python\u5305\n\n```\npip3 install --upgrade -i https://test.pypi.org/simple/ tdf-tools --user\n```\n\n\n\n## \u5de5\u5177\u4f7f\u7528\u6d41\u7a0b\u8bf4\u660e\n\n### 1.\u51c6\u5907\u5de5\u4f5c\n\n- \u786e\u4fddpython\u7684bin\u63d2\u4ef6\u76ee\u5f55\u5df2\u7ecf\u88ab\u914d\u7f6e\u5230\u73af\u5883\u53d8\u91cf\u4e2d\uff08\u8fd9\u4e00\u6b65\u4e0d\u6ee1\u8db3\u7684\u8bdd\uff0c\u63d2\u4ef6\u5b89\u88c5\u4e4b\u540e\u662f\u65e0\u6cd5\u8bc6\u522b\u5230\u672c\u63d2\u4ef6\u547d\u4ee4\u7684\uff09\n\n- \u5728~\u76ee\u5f55\u4e0b\uff0c\u521b\u5efa.tdf_tools_config\u6587\u4ef6\u5e76\u914d\u7f6e\u76f8\u5173\u5fc5\u9700\u5c5e\u6027\u5982\u4e0b\n\n```json\ngit_private_token=***\n```\n\ngit_private_token\u662fgitlab\u7684token\n\n\u83b7\u53d6\u9014\u5f84\uff1a\u8fdb\u5165gitlab\u9875\u9762\uff0c\u70b9\u51fb\u53f3\u4e0a\u89d2\u5934\u50cf\uff0c\u9009\u62e9Preferences\uff0c\u9009\u62e9\u5de6\u4fa7\u5217\u8868\u4e2d\u7684AccessToken\u8fdb\u884c\u521b\u5efa\n\n**\u4e0a\u8ff0\u6b65\u9aa4\u5982\u679c\u6ca1\u6709\u505a\uff0c\u4f1a\u5728\u4f7f\u7528\u63d2\u4ef6\u65f6\uff0c\u4f1a\u6709\u63d0\u793a**\n\n### 2.\u521d\u59cb\u5316\n\n#### i.\u8fdb\u5165\u58f3\u76ee\u5f55\uff08\u786e\u4fdd\u6267\u884c\u547d\u4ee4\u5728\u58f3\u76ee\u5f55\u5185\uff09\n\n#### ii.\u6267\u884ctdf_tools module init\n\n- \u5224\u65ad\u5f53\u524d\u76ee\u5f55\u662f\u5426\u5b58\u5728tdf_cache\uff0c\u82e5\u4e0d\u5b58\u5728\uff0c\u5219\u4f1a\u81ea\u52a8\u521b\u5efatdf_cache\n- \u81ea\u52a8\u8bfb\u53d6\u5f53\u524d\u58f3\u6a21\u5757\u540d\u79f0\uff0c\u5199\u5165initial_config.json\u914d\u7f6e\u6587\u4ef6\uff1b\n- \u8bfb\u53d6\u5f53\u524d\u58f3\u5206\u652f\uff0c\u5199\u5165initial_config.json\u914d\u7f6e\u6587\u4ef6\uff1b\n- \u4ea4\u4e92\u5f0f\u63d0\u793a\u7528\u6237\u8f93\u5165\u9700\u8981\u5f00\u53d1\u7684\u6a21\u5757\u540d\u5e76\u5199\u5165initial_config.json\u914d\u7f6e\u6587\u4ef6\u7684moduleNameList\u5217\u8868\u5b57\u6bb5\u4e2d\n- \uff01\u9000\u51fa\uff0c\u5373\u8f93\u5165\u5b8c\u6210\n- \u81ea\u52a8clone\u6240\u6709\u5f00\u53d1\u6a21\u5757\u5230  ```../.tdf_flutter```  \u9690\u85cf\u76ee\u5f55\u4e2d\uff1b\n- \u5c06\u6240\u6709\u5f00\u53d1\u6a21\u5757\u5206\u652f\u5207\u6362\u81f3\u4e0e\u58f3\u4e00\u81f4\uff1b\n- \u81ea\u52a8\u5206\u6790\u4f9d\u8d56\u6811\uff0c\u5e76**\u7531\u4e0b\u81f3\u4e0a**\u5bf9\u6240\u6709\u6a21\u5757\u81ea\u52a8\u6267\u884c```flutter pub upgrade```;\n\n#### iii.\u5f00\u53d1\u8fc7\u7a0b\u4e2d\n\n##### 1.\u5f00\u53d1\u6a21\u5757\u6dfb\u52a0\n\n- \u82e5\u662f\u6709\u65b0\u6a21\u5757\u9700\u8981\u6dfb\u52a0\u5165\u5f00\u53d1\u6a21\u5757\u4e2d\uff0c\u53ef\u76f4\u63a5\u4fee\u6539initial_config.json\u914d\u7f6e\u6587\u4ef6\uff0c\u4fee\u6539moduleNameList\u5b57\u6bb5\uff1b\n- \u6267\u884ctdf_tools deps\u66f4\u65b0\u4f9d\u8d56\n\n##### 2.\u65b0\u5f00\u53d1\u6a21\u5757\u6dfb\u52a0\n\n- \u6dfb\u52a0\u65b0\u6a21\u5757\u540e\uff0c\u4f1a\u63d0\u793a\u627e\u4e0d\u5230\u6a21\u5757\uff0c\u5b9e\u9645\u67e5\u627e\u7684\u662f```tdf_cache```\u6587\u4ef6\u5939\u4e2d\u7684module_config.json\u6587\u4ef6\uff1b\n- \u5982\u679c\u6ca1\u6709\u627e\u5230\u8be5\u6a21\u5757\uff0c\u5219\u53ef\u4ee5\u6267\u884c```tdf_tools module-update```,\u66f4\u65b0\u8fdc\u7a0bmodule_config.json\u6587\u4ef6\uff1b\n- \u5220\u6389\u672c\u5730\u7684module_config.json\u6587\u4ef6\uff0c\u91cd\u65b0\u6267\u884c\u547d\u4ee4\u5373\u53ef\uff0c\u811a\u672c\u4f1a\u81ea\u52a8\u5224\u65ad\u672c\u5730\u662f\u5426\u5b58\u5728\u8be5\u914d\u7f6e\u6587\u4ef6\uff0c\u5982\u679c\u4e0d\u5b58\u5728\u4f1a**\u4e0b\u8f7d**\uff1b\n\n<span style=\"color:#ff0000\">\u8bf7\u786e\u4fddgitlab\u4ed3\u5e93\u7684\u65b0\u5f00\u53d1\u6a21\u5757master\u5206\u652f\u662f\u4e00\u4e2aflutter\u6a21\u5757\uff0c\u5982\u679c\u5224\u5b9a\u4e0d\u662fflutter\u6a21\u5757\uff0c\u5219\u4f1a\u62a5\u9519\uff08\u5224\u5b9a\u6761\u4ef6\u4e3a\u5b58\u5728pubspec.yaml\u6587\u4ef6\uff09</span>\n\n\n\n### 3.\u7248\u672c\u63a7\u5236\n\n\u7248\u672c\u63a7\u5236\u8bf7\u4f7f\u7528tdf_tools\u547d\u4ee4\uff0c\u547d\u4ee4\u8be6\u60c5\u53ef\u4f7f\u7528  ```tdf_tools -h```  \u67e5\u770b\uff0c\u73b0\u5df2\u652f\u6301\u5927\u90e8\u5206\u547d\u4ee4\uff0c\u82e5\u6709\u7279\u6b8a\u547d\u4ee4\u9700\u8981\u6267\u884c\uff0c\u53ef\u4ee5\u4f7f\u7528  ```tdf_tools <git\u547d\u4ee4>``` \uff0c\u5982\uff1a```tdf_tools git add .```\n\n\n\n### 4.\u81ea\u52a8\u6253\u5305\u53d1\u5e03\n\n\u6682\u672a\u63a5\u5165\u6253\u5305\u5de5\u5177\uff0c\u9884\u8ba1\u4e0b\u4e00\u5b63\u5ea6\u8fdb\u884c\u652f\u6301\uff1b\n\n\n\n**<span style=\"color:#ff0000\">FAQ</span>**\n\nwindows\u7cfb\u7edf\u8bf7\u4f7f\u7528bash\u547d\u4ee4\uff1b\n\n\n\n## \u989d\u5916\u529f\u80fd\u8bf4\u660e\n\n### 1.\u4e8c\u7ef4\u6570\u7ec4\u8868\u8fbe\u4f9d\u8d56\u6811\n\n\u751f\u6210\u4e00\u4e2a\u4e8c\u7ef4\u6570\u7ec4\uff0c\u53ef\u6839\u636e\u8be5\u4e8c\u7ef4\u6570\u7ec4\u7684\u6570\u636e\u8fdb\u884c**\u5e76\u53d1**\u6253tag\uff0c\u6bcf\u4e00\u5c42\u7684\u6a21\u5757\uff0c\u90fd\u53ef\u4ee5\u540c\u65f6\u8fdb\u884c\u6253tag\u53d1\u5e03\u64cd\u4f5c\uff0c\u51cf\u5c11\u53d1\u5e03\u8017\u65f6\uff1b\n\n```json\n[\n\t[\"tdf_channel\", \"tdf_event\", \"tdf_network\"], \n\t[\"tdf_widgets\"], \n\t[\"tdf_smart_devices\", \"tdf_account_module\"], \n\t[\"flutter_reset_module\"]\n]\n```\n\n\u5982\u4e0a\u6570\u636e\uff0c\u6570\u7ec4\u4e2d\u6bcf\u4e00\u4e2a\u8282\u70b9\u4e2d\u7684\u6a21\u5757\u5747\u53ef\u540c\u65f6\u6253tag\uff0c\u8282\u70b9\u4e4b\u95f4\u9700\u8981\u7531\u4e0a\u81f3\u4e0b\u7684\u987a\u5e8f\u8fdb\u884ctag\u64cd\u4f5c\n\n\n\n### 2.\u63d2\u4ef6\u66f4\u65b0\n\n\u6267\u884c ```tdf_tools upgrade```\n\n\n\n### 3.\u8fdc\u7a0b\u6a21\u5757\u914d\u7f6e\u6587\u4ef6\u66f4\u65b0\n\n\u6267\u884c ```tdf_tools module module_update```\n\n\n\n## \u4f9d\u8d56\u6811\u5206\u6790\u539f\u7406\n\n\u91c7\u7528\u6709\u5411\u6709/\u65e0\u73af\u56fe\u8fdb\u884c\u4f9d\u8d56\u6811\u7684\u5206\u6790\n\n\u6570\u636e\u7ed3\u6784\u91c7\u7528\u5982\u4e0b\uff1a\n\n```python\nclass DependencyNode:\n    def __init__(self):\n        self.nodeName = ''\n        self.parent = []  # \u7236\u4eb2\u8282\u70b9\u5217\u8868\n        self.children = []  # \u5b50\u5b59\u8282\u70b9\u5217\u8868\n        self.delete = False\n```\n\n![dependency](./README_DIR/dependency.png)\n\n\u5982\u4e0a\u56fe1\uff1a\u4e00\u4e2a\u6b63\u5e38\u7684\u4f9d\u8d56\u6811\u8868\u793a\uff1b\n\n\u5982\u4e0a\u56fe2\uff1a\u5bf9\u56fe1\u4e2d\uff0c\u4f9d\u8d56\u6811\u6240\u6709\u8282\u70b9\u53bb\u91cd\uff0c\u53d8\u6362\u4e3a\u56fe2\u6709\u5411\u56fe\uff1b\t\n\n\n\n**\u5206\u6790\u6d41\u7a0b\uff1a**\n\n**\u4f9d\u8d56\u56fe\u6784\u5efa**\n\n```python\n# \u751f\u6210\u4f9d\u8d56\u56fe\n    def _generateDependenciesMap(self):\n        for package in self.__moduleDependenciesMap:\n            for module in moduleNameList:\n                if package == module:\n                    # \u5230\u8fd9\u4e00\u6b65\u8868\u660e\u5f53\u524d\u8fd9\u4e2a\u6a21\u5757\u5c5e\u4e8e\u5f00\u53d1\u6a21\u5757\u4e14\u5728\u5f53\u524d\u6a21\u5757\u7684\u4f9d\u8d56\u6a21\u5757\u5217\u8868\u4e2d\uff0c\u662f\u5f53\u524d\u6a21\u5757\u7684\u5b50\u6a21\u5757\n                    self._mNodeDict[self.__moduleName].children.append(package)\n                    self._mNodeDict[package].parent.append(self.__moduleName)\n```\n\n- \u51715\u4e2a\u8282\u70b9\n\n  - node\u6784\u5efa\uff1a\n\n    - ```python\n      {\n      \t\"\u6a21\u57571\":{\n          \"nodeNmae\": \"\u6a21\u57571\",\n          \"parent\": [],\n          \"children\": [\"\u6a21\u57572\",\"\u6a21\u57573\",\"\u6a21\u57574\",\"\u6a21\u57575\"],\n          \"delete\": False\n      \t},\n      \t\"\u6a21\u57572\":{\n          \"nodeNmae\": \"\u6a21\u57572\",\n          \"parent\": [\"\u6a21\u57571\"],\n          \"children\": [\"\u6a21\u57574\",\"\u6a21\u57575\"],\n          \"delete\": False\n      \t}\n      \t\"\u6a21\u57573\":{\n          \"nodeNmae\": \"\u6a21\u57573\",\n          \"parent\": [\"\u6a21\u57571\"],\n          \"children\": [\"\u6a21\u57575\"],\n          \"delete\": False\n      \t}\n      \t\"\u6a21\u57574\":{\n          \"nodeNmae\": \"\u6a21\u57574\",\n          \"parent\": [\"\u6a21\u57571\",\"\u6a21\u57572\"],\n          \"children\": [],\n          \"delete\": False\n      \t}\n      \t\"\u6a21\u57575\":{\n          \"nodeNmae\": \"\u6a21\u57575\",\n          \"parent\": [\"\u6a21\u57571\",\"\u6a21\u57572\",\"\u6a21\u57573\"],\n          \"children\": [],\n          \"delete\": False\n      \t}\n      }\n      ```\n\n**\u4f9d\u8d56\u56fe\u89e3\u6790\u4f2a\u4ee3\u7801\uff08\u4ee5\u4e00\u7ef4\u6570\u7ec4\u4e3a\u4f8b\uff09**\n\n```python\n# \u8fd4\u56de\u4e8c\u7ef4\u6570\u7ec4\uff0c\u7528\u4e8e\u5e76\u53d1\u6253tag\n    def _generateDependenciesOrder(self):\n        resList = []\n        while \u5b58\u5728\u8282\u70b9delete\u5c5e\u6027\u4e0d\u4e3aTrue:\n            \n            for\uff1a\u67e5\u627e\u5b50\u8282\u70b9\u4e3a0\u7684\u8282\u70b9\n            \t\u8bbe\u7f6e\u8282\u70b9delete\u5c5e\u6027\u4e3aTrue\n              \n            for\uff1adeleteItemList = \u62ff\u5230\u6240\u6709delete\u5c5e\u6027\u4e3atrue\u7684\u8282\u70b9\n\n            for\uff1a\u904d\u5386\u6240\u6709\u8282\u70b9\uff0c\u5982\u679c\u8282\u70b9\u7684\u5b50\u8282\u70b9\u4e2d\u5305\u542bdeleteItemList\u7684\u8282\u70b9\uff0c\u5219\u5c06\u5176\u4ece\u5b50\u8282\u70b9\u5217\u8868\u4e2d\u5220\u9664\n```\n\n\n\n\n\n- **initial_config.json\u6587\u4ef6\u8bf4\u660e**\n\n  ```json\n  {\n      \"featureBranch\": \"feature/test_dev_1\", // \u5f00\u53d1\u5206\u652f\n      \"shellName\": \"flutter_reset_module\",\n      // \u9879\u76ee\u9700\u8981\u5f00\u53d1\u7684\u6a21\u5757,\u53ef\u81ea\u7531\u914d\u7f6e\n      \"moduleNameList\": [\n          \"flutter_reset_module\",\n          \"tdf_smart_devices\",\n          \"tdf_widgets\",\n          \"tdf_channel\"\n      ]\n  }\n  ```\n\n- **module_config.json\u6587\u4ef6\u8bf4\u660e**\n\n  ```json\n  {\n      \"flutter_globalyun_us_module\": {\n        \t\"id\": \"11111\"\n          \"type\": \"shell\",\n          \"git\": \"git@git.2dfire.net:app/flutter/app/flutter_globalyun_us_module.git\"\n      },\n      \"tdf_router_anno\": {\n          \"type\": \"base\",\n          \"git\": \"git@git.2dfire.net:app/flutter/app/tdf_router_anno.git\"\n      },\n  }\n  //\u8bed\u610f\n  {\n    \"\u6a21\u5757\u540d\":{\n      \"id\": \u9879\u76eegitlab id\n      \"\u7c7b\u578b\": gitlab group\u540d\n      \"git\": gitlab\u5730\u5740\n    }\n  }\n  ```\n\n\n\n## \u540e\u7eed\u8ba1\u5212\n\n<span style=\"color:#ff0000\">**\u95ee\u9898\uff1a**</span>\u7531\u4e8e\u73b0\u5728flutter ci \u3010lint\u3011\u3010tag\u3011\u4efb\u52a1\u811a\u672c\u6210\u529f\u7387\u8fc7\u4e8e\u4f4e\uff0c\u5f88\u591a\u65f6\u5019\u662f\u56e0\u4e3a\u9879\u76ee\u6a21\u5757\u7684\u914d\u7f6e\u95ee\u9898\u5bfc\u81f4\u7684\uff0c\u4e14\u540e\u7eed\u4f1a\u63a5\u5165\u4e00\u952e\u6253tag\u5de5\u5177\n\n\u65b9\u6848\uff1a\u5728\u6267\u884c\u7edf\u4e00push\u524d\uff0c\u5bf9\u6240\u6709\u6a21\u5757\u7684\u9879\u76ee\u914d\u7f6e\u4fe1\u606f\u8fdb\u884c\u6821\u9a8c\uff0c\u786e\u4fdd\u6570\u636e\u89c4\u8303\uff1b\n\n\n\n## \u63d2\u4ef6\u6253\u5305\u53d1\u5e03\u547d\u4ee4\n\n**\u63d2\u4ef6\u6253\u5305\u547d\u4ee4**\n\n```\npoetry build\n```\n**\u63d2\u4ef6\u53d1\u5e03\u547d\u4ee4**\n\n```\npoetry publish\n```\n\n## History\n\n### 2.1.00\n\n- \u8def\u7531\u529f\u80fd\u652f\u6301flutter\u7248\u672c3.3.10\uff0c\u517c\u5bb9flutter\u7248\u672c2.2.3\uff1b\n\n### 2.0.61\n\n- Flutter\u56fd\u9645\u5316\u5b57\u7b26\u4e32\u6574\u5408\uff1b\n\n### 2.0.38\n\n- \u8def\u7531\u751f\u6210\u5b8c\u540e\u589e\u52a0\u8def\u7531\u76f8\u5173\u4ee3\u7801format\uff08\u89e3\u51b3windows\u4ee3\u7801\u751f\u6210\u540e\u987a\u5e8f\u9519\u4e71\uff09\uff1b\n\n### 2.0.01\n\n- Cli \u6846\u67b6\u5347\u7ea7\uff1b\n- \u4ee3\u7801\u91cd\u6784\uff1b\n\n### **1.1.00\uff082022-4-28\uff09**\n\n- \u56fd\u9645\u5316\u89e3\u51b3\u8f93\u51fajson\u4e2d\u5305\u542b\u8f6c\u4e49\u5b57\u7b26\u7684\u95ee\u9898\uff0c\u5982\\n\uff1b\n- \u56db\u7c7b\u8bed\u8a00\u8f93\u51fa\u6587\u4ef6\u81ea\u52a8\u683c\u5f0f\u5316\n\n### **1.0.55\uff082022-4-28\uff09**\n\n- \u56fd\u9645\u5316key\u4f7f\u7528\u4e2d\u6587\uff08\u4f9d\u7167ios\u9879\u76ee\u5f00\u53d1\u5f62\u5f0f\uff09\uff1b\n\n### **1.0.53\uff082022-4-28\uff09**\n\n- \u56fd\u9645\u5316\u6d41\u7a0b\u4e2d\uff0c\u517c\u5bb9\u89e3\u51b3\u90e8\u5206json\u89e3\u6790\u5931\u8d25\u95ee\u9898\uff0c\u8b6c\u5982\u5b57\u7b26\u4e32\u4e2d\u5305\u542b\"=\"\u7b26\u53f7\uff1b\n\n> \u9519\u8bef\u65e5\u5fd7\u5982\uff1aUnterminated string starting at: line 1 column 5650 (char 5649)\n\n### **1.0.50\uff082022-4-28\uff09**\n\n- \u56fd\u9645\u5316\u589e\u52a0\u7e41\u4f53\u5b57\u7ffb\u8bd1\uff1b\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "\u4e8c\u7ef4\u706b flutter \u811a\u624b\u67b6\u5de5\u5177",
    "version": "2.1.3",
    "split_keywords": [
        "tdf",
        "tdf-tools",
        "tdf_tools"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4abedc89bcce77949efa6c4ab46de8b77e49657c155eeedd89bf68d1c9e6ed34",
                "md5": "d2cdcf18bffaa12cff6b8caa3780662e",
                "sha256": "477a21cc061efac172fa14fdf22e67a9fe5ce5d296f8b49b4d29255241db6fb7"
            },
            "downloads": -1,
            "filename": "tdf_tools-2.1.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "d2cdcf18bffaa12cff6b8caa3780662e",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9.0,<4.0.0",
            "size": 74743,
            "upload_time": "2023-01-17T06:56:12",
            "upload_time_iso_8601": "2023-01-17T06:56:12.560259Z",
            "url": "https://files.pythonhosted.org/packages/4a/be/dc89bcce77949efa6c4ab46de8b77e49657c155eeedd89bf68d1c9e6ed34/tdf_tools-2.1.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "91d02fe77748076c29cfbca5301663364da3bcb8f7680b602e1cd763b3da6ae2",
                "md5": "7cabe40fdb5d5c141a24c7db5d7506dc",
                "sha256": "0a38233643c7250027b49b65c74875ea479f2122d65f3e55f569a8bf22ff6e28"
            },
            "downloads": -1,
            "filename": "tdf_tools-2.1.3.tar.gz",
            "has_sig": false,
            "md5_digest": "7cabe40fdb5d5c141a24c7db5d7506dc",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9.0,<4.0.0",
            "size": 138362,
            "upload_time": "2023-01-17T06:56:16",
            "upload_time_iso_8601": "2023-01-17T06:56:16.170889Z",
            "url": "https://files.pythonhosted.org/packages/91/d0/2fe77748076c29cfbca5301663364da3bcb8f7680b602e1cd763b3da6ae2/tdf_tools-2.1.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-01-17 06:56:16",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "tdf-tools"
}
        
Elapsed time: 0.03542s