Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🎨优化自定义工具拉取依赖逻辑 #631

Merged
merged 2 commits into from
Sep 28, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions client/node/localtask/taskprocessmgr.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,7 @@ def get_supported_processes(origin_os_env, task_name, task_params, custom_tools)
# 加载工具执行需要的环境变量
task_params["tool_name"] = task_name
task_list = ConfigUtil.generate_task_list(task_params)
if ConfigUtil.use_new_tool_lib_config(task_params): # 使用依赖库配置
tool_names = [task_name]
else: # 使用ini配置
if task_name in custom_tools:
tool_names = ["customtool"]
else:
tool_names = [task_name]
ToolLoader(tool_names=tool_names, task_list=task_list, custom_tools=custom_tools,
ToolLoader(tool_names=[task_name], task_list=task_list, custom_tools=custom_tools,
include_common=True).set_tool_env()

# 加载任务环境变量
Expand Down
Binary file modified client/task/runtask.cp37-win_amd64.pyd
Binary file not shown.
Binary file modified client/task/runtask.cpython-37m-aarch64-linux-gnu.so
Binary file not shown.
Binary file modified client/task/runtask.cpython-37m-darwin.so
Binary file not shown.
Binary file modified client/task/runtask.cpython-37m-x86_64-linux-gnu.so
Binary file not shown.
Binary file modified client/tool/customtool.cp37-win_amd64.pyd
Binary file not shown.
Binary file modified client/tool/customtool.cpython-37m-aarch64-linux-gnu.so
Binary file not shown.
Binary file modified client/tool/customtool.cpython-37m-darwin.so
Binary file not shown.
Binary file modified client/tool/customtool.cpython-37m-x86_64-linux-gnu.so
Binary file not shown.
3 changes: 3 additions & 0 deletions client/util/scmurlmgr.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ def get_last_dir_name_from_url(scm_url):
dirname = dirname.replace(".zip", "")
if dirname.endswith(".7z"):
dirname = dirname.replace(".7z", "")
# 如果url包含分支,即 .git#BranchName 的格式,目录名删除.git
if ".git#" in dirname:
dirname = dirname.replace(".git#", "#")
return dirname


Expand Down