diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 0d0e2fe1e..a060d46f5 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -24,6 +24,13 @@ jobs: - name: Checkout Repo uses: actions/checkout@v3 + # 下载二进制文件 + - name: Download Binary Files + run: | + set -ex + pwd + bash ./scripts/base/install_bin.sh + - name: Setup Node 16 uses: actions/setup-node@v3 with: diff --git "a/doc/images/API\347\232\204\344\270\252\344\272\272\344\273\244\347\211\214.png" "b/doc/images/API\347\232\204\344\270\252\344\272\272\344\273\244\347\211\214.png" deleted file mode 100644 index 27ce1635c..000000000 Binary files "a/doc/images/API\347\232\204\344\270\252\344\272\272\344\273\244\347\211\214.png" and /dev/null differ diff --git a/doc/images/AddRule.png b/doc/images/AddRule.png deleted file mode 100644 index a8d26ca31..000000000 Binary files a/doc/images/AddRule.png and /dev/null differ diff --git a/doc/images/AddRule2.png b/doc/images/AddRule2.png deleted file mode 100644 index facf51a29..000000000 Binary files a/doc/images/AddRule2.png and /dev/null differ diff --git a/doc/images/AddRule3.png b/doc/images/AddRule3.png deleted file mode 100644 index 6b3e9dd2d..000000000 Binary files a/doc/images/AddRule3.png and /dev/null differ diff --git a/doc/images/Fork.png b/doc/images/Fork.png deleted file mode 100644 index 99895e1b4..000000000 Binary files a/doc/images/Fork.png and /dev/null differ diff --git a/doc/images/NewPullRequest.png b/doc/images/NewPullRequest.png deleted file mode 100644 index ad6b12ebb..000000000 Binary files a/doc/images/NewPullRequest.png and /dev/null differ diff --git a/doc/images/Nodemanagement.png b/doc/images/Nodemanagement.png deleted file mode 100644 index dd566582e..000000000 Binary files a/doc/images/Nodemanagement.png and /dev/null differ diff --git a/doc/images/PR.png b/doc/images/PR.png deleted file mode 100644 index 5321bc135..000000000 Binary files a/doc/images/PR.png and /dev/null differ diff --git a/doc/images/ProcessConfiguration2.png b/doc/images/ProcessConfiguration2.png deleted file mode 100644 index 0b283f7d9..000000000 Binary files a/doc/images/ProcessConfiguration2.png and /dev/null differ diff --git a/doc/images/Welcome.png b/doc/images/Welcome.png deleted file mode 100644 index 0184d09b4..000000000 Binary files a/doc/images/Welcome.png and /dev/null differ diff --git a/doc/images/addcustomrules.png b/doc/images/addcustomrules.png deleted file mode 100644 index a6749e7c8..000000000 Binary files a/doc/images/addcustomrules.png and /dev/null differ diff --git a/doc/images/clientConfigIni.png b/doc/images/clientConfigIni.png deleted file mode 100644 index 89e05b26a..000000000 Binary files a/doc/images/clientConfigIni.png and /dev/null differ diff --git a/doc/images/codelint_01.png b/doc/images/codelint_01.png deleted file mode 100644 index ce5098c2c..000000000 Binary files a/doc/images/codelint_01.png and /dev/null differ diff --git a/doc/images/codelint_02.png b/doc/images/codelint_02.png deleted file mode 100644 index 406a93799..000000000 Binary files a/doc/images/codelint_02.png and /dev/null differ diff --git a/doc/images/codelint_03.png b/doc/images/codelint_03.png deleted file mode 100644 index d013b2511..000000000 Binary files a/doc/images/codelint_03.png and /dev/null differ diff --git a/doc/images/codelint_04.png b/doc/images/codelint_04.png deleted file mode 100644 index b315bc7bf..000000000 Binary files a/doc/images/codelint_04.png and /dev/null differ diff --git a/doc/images/creataAnalysePlan.png b/doc/images/creataAnalysePlan.png deleted file mode 100644 index 82cdbeeb9..000000000 Binary files a/doc/images/creataAnalysePlan.png and /dev/null differ diff --git a/doc/images/createProject.png b/doc/images/createProject.png deleted file mode 100644 index d0400a326..000000000 Binary files a/doc/images/createProject.png and /dev/null differ diff --git a/doc/images/createTeam.png b/doc/images/createTeam.png deleted file mode 100644 index 5056418b7..000000000 Binary files a/doc/images/createTeam.png and /dev/null differ diff --git a/doc/images/create_repo.png b/doc/images/create_repo.png deleted file mode 100644 index 2dab3e3cf..000000000 Binary files a/doc/images/create_repo.png and /dev/null differ diff --git a/doc/images/create_team.png b/doc/images/create_team.png deleted file mode 100644 index 05fca9102..000000000 Binary files a/doc/images/create_team.png and /dev/null differ diff --git a/doc/images/create_team_group.png b/doc/images/create_team_group.png deleted file mode 100644 index 41c0fc4d9..000000000 Binary files a/doc/images/create_team_group.png and /dev/null differ diff --git a/doc/images/createcustomrule.png b/doc/images/createcustomrule.png deleted file mode 100644 index faad029e5..000000000 Binary files a/doc/images/createcustomrule.png and /dev/null differ diff --git a/doc/images/customtool_01.png b/doc/images/customtool_01.png deleted file mode 100644 index 80d9364f2..000000000 Binary files a/doc/images/customtool_01.png and /dev/null differ diff --git a/doc/images/customtool_02.png b/doc/images/customtool_02.png deleted file mode 100644 index 6e5d788ac..000000000 Binary files a/doc/images/customtool_02.png and /dev/null differ diff --git a/doc/images/customtool_03.png b/doc/images/customtool_03.png deleted file mode 100644 index eca12883a..000000000 Binary files a/doc/images/customtool_03.png and /dev/null differ diff --git a/doc/images/customtool_04.png b/doc/images/customtool_04.png deleted file mode 100644 index 47f34630e..000000000 Binary files a/doc/images/customtool_04.png and /dev/null differ diff --git a/doc/images/customtool_05.png b/doc/images/customtool_05.png deleted file mode 100644 index 25bd2c203..000000000 Binary files a/doc/images/customtool_05.png and /dev/null differ diff --git a/doc/images/customtool_06.png b/doc/images/customtool_06.png deleted file mode 100644 index af530ad1b..000000000 Binary files a/doc/images/customtool_06.png and /dev/null differ diff --git a/doc/images/fork1.png b/doc/images/fork1.png deleted file mode 100644 index f93cdcbe5..000000000 Binary files a/doc/images/fork1.png and /dev/null differ diff --git a/doc/images/gitlab_application_01.png b/doc/images/gitlab_application_01.png deleted file mode 100644 index dc85658ba..000000000 Binary files a/doc/images/gitlab_application_01.png and /dev/null differ diff --git a/doc/images/gitlab_application_02.png b/doc/images/gitlab_application_02.png deleted file mode 100644 index 89942faf9..000000000 Binary files a/doc/images/gitlab_application_02.png and /dev/null differ diff --git a/doc/images/gitlab_application_03.png b/doc/images/gitlab_application_03.png deleted file mode 100644 index 09e999b89..000000000 Binary files a/doc/images/gitlab_application_03.png and /dev/null differ diff --git a/doc/images/gitlab_application_04.png b/doc/images/gitlab_application_04.png deleted file mode 100644 index d18799d31..000000000 Binary files a/doc/images/gitlab_application_04.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_QA_01.png b/doc/images/gitlab_oauth_QA_01.png deleted file mode 100644 index f0e51e148..000000000 Binary files a/doc/images/gitlab_oauth_QA_01.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_QA_02.png b/doc/images/gitlab_oauth_QA_02.png deleted file mode 100644 index a6b8b478e..000000000 Binary files a/doc/images/gitlab_oauth_QA_02.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_QA_03.png b/doc/images/gitlab_oauth_QA_03.png deleted file mode 100644 index 35673c555..000000000 Binary files a/doc/images/gitlab_oauth_QA_03.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_QA_04.png b/doc/images/gitlab_oauth_QA_04.png deleted file mode 100644 index 1c4e57388..000000000 Binary files a/doc/images/gitlab_oauth_QA_04.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_QA_05.png b/doc/images/gitlab_oauth_QA_05.png deleted file mode 100644 index 197ebdc24..000000000 Binary files a/doc/images/gitlab_oauth_QA_05.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_QA_06.png b/doc/images/gitlab_oauth_QA_06.png deleted file mode 100644 index 88a141aa0..000000000 Binary files a/doc/images/gitlab_oauth_QA_06.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_QA_07.png b/doc/images/gitlab_oauth_QA_07.png deleted file mode 100644 index 92d330d3a..000000000 Binary files a/doc/images/gitlab_oauth_QA_07.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_disposition_01.png b/doc/images/gitlab_oauth_disposition_01.png deleted file mode 100644 index d57ad0fb2..000000000 Binary files a/doc/images/gitlab_oauth_disposition_01.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_disposition_02.png b/doc/images/gitlab_oauth_disposition_02.png deleted file mode 100644 index 36bc7afe8..000000000 Binary files a/doc/images/gitlab_oauth_disposition_02.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_disposition_03.png b/doc/images/gitlab_oauth_disposition_03.png deleted file mode 100644 index 88e929ccd..000000000 Binary files a/doc/images/gitlab_oauth_disposition_03.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_disposition_04.png b/doc/images/gitlab_oauth_disposition_04.png deleted file mode 100644 index e46ec0306..000000000 Binary files a/doc/images/gitlab_oauth_disposition_04.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_disposition_05.png b/doc/images/gitlab_oauth_disposition_05.png deleted file mode 100644 index 18c0fc327..000000000 Binary files a/doc/images/gitlab_oauth_disposition_05.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_disposition_06.png b/doc/images/gitlab_oauth_disposition_06.png deleted file mode 100644 index 36ebbb5a9..000000000 Binary files a/doc/images/gitlab_oauth_disposition_06.png and /dev/null differ diff --git a/doc/images/gitlab_oauth_disposition_07.png b/doc/images/gitlab_oauth_disposition_07.png deleted file mode 100644 index b84264219..000000000 Binary files a/doc/images/gitlab_oauth_disposition_07.png and /dev/null differ diff --git a/doc/images/golangcilint.jpg b/doc/images/golangcilint.jpg deleted file mode 100644 index 4f90104e9..000000000 Binary files a/doc/images/golangcilint.jpg and /dev/null differ diff --git a/doc/images/golangcilintversion.jpg b/doc/images/golangcilintversion.jpg deleted file mode 100644 index 6934a4c32..000000000 Binary files a/doc/images/golangcilintversion.jpg and /dev/null differ diff --git a/doc/images/homepage.png b/doc/images/homepage.png deleted file mode 100644 index b964a420f..000000000 Binary files a/doc/images/homepage.png and /dev/null differ diff --git a/doc/images/jenkins_build.png b/doc/images/jenkins_build.png deleted file mode 100644 index dc5beb320..000000000 Binary files a/doc/images/jenkins_build.png and /dev/null differ diff --git a/doc/images/jenkins_console_output.png b/doc/images/jenkins_console_output.png deleted file mode 100644 index e16682814..000000000 Binary files a/doc/images/jenkins_console_output.png and /dev/null differ diff --git a/doc/images/jenkins_deploy_plugin.png b/doc/images/jenkins_deploy_plugin.png deleted file mode 100644 index 6b475645d..000000000 Binary files a/doc/images/jenkins_deploy_plugin.png and /dev/null differ diff --git a/doc/images/jenkins_environment_vars.png b/doc/images/jenkins_environment_vars.png deleted file mode 100644 index 3136f5ead..000000000 Binary files a/doc/images/jenkins_environment_vars.png and /dev/null differ diff --git a/doc/images/jenkins_git_config.png b/doc/images/jenkins_git_config.png deleted file mode 100644 index de8be5ee0..000000000 Binary files a/doc/images/jenkins_git_config.png and /dev/null differ diff --git a/doc/images/jenkins_installed_plugins.png b/doc/images/jenkins_installed_plugins.png deleted file mode 100644 index 754e5497e..000000000 Binary files a/doc/images/jenkins_installed_plugins.png and /dev/null differ diff --git a/doc/images/jenkins_manage_jenkins.png b/doc/images/jenkins_manage_jenkins.png deleted file mode 100644 index 4defd730d..000000000 Binary files a/doc/images/jenkins_manage_jenkins.png and /dev/null differ diff --git a/doc/images/jenkins_manage_plugins.png b/doc/images/jenkins_manage_plugins.png deleted file mode 100644 index 554fa5b22..000000000 Binary files a/doc/images/jenkins_manage_plugins.png and /dev/null differ diff --git a/doc/images/jenkins_new_item.png b/doc/images/jenkins_new_item.png deleted file mode 100644 index 2e748c77c..000000000 Binary files a/doc/images/jenkins_new_item.png and /dev/null differ diff --git a/doc/images/jenkins_output_url.png b/doc/images/jenkins_output_url.png deleted file mode 100644 index 66cb2d6e0..000000000 Binary files a/doc/images/jenkins_output_url.png and /dev/null differ diff --git a/doc/images/jenkins_shell.png b/doc/images/jenkins_shell.png deleted file mode 100644 index b0ff0a7af..000000000 Binary files a/doc/images/jenkins_shell.png and /dev/null differ diff --git a/doc/images/jenkins_tca_plugin_config.png b/doc/images/jenkins_tca_plugin_config.png deleted file mode 100644 index b8fed42d3..000000000 Binary files a/doc/images/jenkins_tca_plugin_config.png and /dev/null differ diff --git a/doc/images/jenkins_var_path.png b/doc/images/jenkins_var_path.png deleted file mode 100644 index 83a285d1a..000000000 Binary files a/doc/images/jenkins_var_path.png and /dev/null differ diff --git a/doc/images/logo.png b/doc/images/logo.png deleted file mode 100644 index aab4be80c..000000000 Binary files a/doc/images/logo.png and /dev/null differ diff --git a/doc/images/manage_job_01.png b/doc/images/manage_job_01.png deleted file mode 100644 index 973333db7..000000000 Binary files a/doc/images/manage_job_01.png and /dev/null differ diff --git a/doc/images/manage_node_01.png b/doc/images/manage_node_01.png deleted file mode 100644 index 5012308be..000000000 Binary files a/doc/images/manage_node_01.png and /dev/null differ diff --git a/doc/images/manage_node_02.png b/doc/images/manage_node_02.png deleted file mode 100644 index 217aa7d0c..000000000 Binary files a/doc/images/manage_node_02.png and /dev/null differ diff --git a/doc/images/manage_node_03.png b/doc/images/manage_node_03.png deleted file mode 100644 index 1b6067e8d..000000000 Binary files a/doc/images/manage_node_03.png and /dev/null differ diff --git a/doc/images/manage_node_04.png b/doc/images/manage_node_04.png deleted file mode 100644 index d6d2c3a6d..000000000 Binary files a/doc/images/manage_node_04.png and /dev/null differ diff --git a/doc/images/manage_oauth_01.png b/doc/images/manage_oauth_01.png deleted file mode 100644 index cbc3b1e7b..000000000 Binary files a/doc/images/manage_oauth_01.png and /dev/null differ diff --git a/doc/images/manage_oauth_02.png b/doc/images/manage_oauth_02.png deleted file mode 100644 index 0092c52a1..000000000 Binary files a/doc/images/manage_oauth_02.png and /dev/null differ diff --git a/doc/images/manage_org_01.png b/doc/images/manage_org_01.png deleted file mode 100644 index 37e62f2a0..000000000 Binary files a/doc/images/manage_org_01.png and /dev/null differ diff --git a/doc/images/manage_org_02.png b/doc/images/manage_org_02.png deleted file mode 100644 index 52161dea1..000000000 Binary files a/doc/images/manage_org_02.png and /dev/null differ diff --git a/doc/images/manage_team_01.png b/doc/images/manage_team_01.png deleted file mode 100644 index ff5908bbb..000000000 Binary files a/doc/images/manage_team_01.png and /dev/null differ diff --git a/doc/images/manage_tool_01.png b/doc/images/manage_tool_01.png deleted file mode 100644 index 2cf005f66..000000000 Binary files a/doc/images/manage_tool_01.png and /dev/null differ diff --git a/doc/images/manage_user_01.png b/doc/images/manage_user_01.png deleted file mode 100644 index 8596ee282..000000000 Binary files a/doc/images/manage_user_01.png and /dev/null differ diff --git a/doc/images/manage_user_02.png b/doc/images/manage_user_02.png deleted file mode 100644 index 9a955cc49..000000000 Binary files a/doc/images/manage_user_02.png and /dev/null differ diff --git a/doc/images/node_mange.png b/doc/images/node_mange.png deleted file mode 100644 index f9fcd4760..000000000 Binary files a/doc/images/node_mange.png and /dev/null differ diff --git a/doc/images/org_node_manager_1.png b/doc/images/org_node_manager_1.png deleted file mode 100644 index 375447db2..000000000 Binary files a/doc/images/org_node_manager_1.png and /dev/null differ diff --git a/doc/images/org_node_manager_2.png b/doc/images/org_node_manager_2.png deleted file mode 100644 index db937ee4e..000000000 Binary files a/doc/images/org_node_manager_2.png and /dev/null differ diff --git a/doc/images/org_node_process.png b/doc/images/org_node_process.png deleted file mode 100644 index 758092622..000000000 Binary files a/doc/images/org_node_process.png and /dev/null differ diff --git a/doc/images/org_tag_manager.png b/doc/images/org_tag_manager.png deleted file mode 100644 index f3cfdaa27..000000000 Binary files a/doc/images/org_tag_manager.png and /dev/null differ diff --git a/doc/images/org_tag_node.png b/doc/images/org_tag_node.png deleted file mode 100644 index 890af1469..000000000 Binary files a/doc/images/org_tag_node.png and /dev/null differ diff --git a/doc/images/org_tag_scheme.png b/doc/images/org_tag_scheme.png deleted file mode 100644 index b8c352587..000000000 Binary files a/doc/images/org_tag_scheme.png and /dev/null differ diff --git a/doc/images/orgsid.png b/doc/images/orgsid.png deleted file mode 100644 index 7b53c6d69..000000000 Binary files a/doc/images/orgsid.png and /dev/null differ diff --git a/doc/images/personalToken.png b/doc/images/personalToken.png deleted file mode 100644 index 78e5cdba9..000000000 Binary files a/doc/images/personalToken.png and /dev/null differ diff --git a/doc/images/planPage.png b/doc/images/planPage.png deleted file mode 100644 index eb90909fb..000000000 Binary files a/doc/images/planPage.png and /dev/null differ diff --git a/doc/images/registerCodeRepo.png b/doc/images/registerCodeRepo.png deleted file mode 100644 index 647cdb287..000000000 Binary files a/doc/images/registerCodeRepo.png and /dev/null differ diff --git a/doc/images/scheme_codelint_01.png b/doc/images/scheme_codelint_01.png deleted file mode 100644 index d2809c35f..000000000 Binary files a/doc/images/scheme_codelint_01.png and /dev/null differ diff --git a/doc/images/scheme_codelint_02.png b/doc/images/scheme_codelint_02.png deleted file mode 100644 index 1bd1763f7..000000000 Binary files a/doc/images/scheme_codelint_02.png and /dev/null differ diff --git a/doc/images/scheme_codelint_03.png b/doc/images/scheme_codelint_03.png deleted file mode 100644 index fe470afc2..000000000 Binary files a/doc/images/scheme_codelint_03.png and /dev/null differ diff --git a/doc/images/scheme_codelint_04.png b/doc/images/scheme_codelint_04.png deleted file mode 100644 index 7b83f587e..000000000 Binary files a/doc/images/scheme_codelint_04.png and /dev/null differ diff --git a/doc/images/scheme_template_01.png b/doc/images/scheme_template_01.png deleted file mode 100644 index cd002101c..000000000 Binary files a/doc/images/scheme_template_01.png and /dev/null differ diff --git a/doc/images/scheme_template_02.png b/doc/images/scheme_template_02.png deleted file mode 100644 index 05e9854ee..000000000 Binary files a/doc/images/scheme_template_02.png and /dev/null differ diff --git a/doc/images/start_scan_01.png b/doc/images/start_scan_01.png deleted file mode 100644 index f72d232bd..000000000 Binary files a/doc/images/start_scan_01.png and /dev/null differ diff --git a/doc/images/start_scan_02.png b/doc/images/start_scan_02.png deleted file mode 100644 index 0b02dc7d0..000000000 Binary files a/doc/images/start_scan_02.png and /dev/null differ diff --git a/doc/images/start_scan_03.png b/doc/images/start_scan_03.png deleted file mode 100644 index df2611126..000000000 Binary files a/doc/images/start_scan_03.png and /dev/null differ diff --git a/doc/images/start_scan_04.png b/doc/images/start_scan_04.png deleted file mode 100644 index f84b627dd..000000000 Binary files a/doc/images/start_scan_04.png and /dev/null differ diff --git a/doc/images/start_scan_05.png b/doc/images/start_scan_05.png deleted file mode 100644 index 881e3fe9c..000000000 Binary files a/doc/images/start_scan_05.png and /dev/null differ diff --git a/doc/images/start_scan_06.png b/doc/images/start_scan_06.png deleted file mode 100644 index eb9bfc436..000000000 Binary files a/doc/images/start_scan_06.png and /dev/null differ diff --git a/doc/images/team.png b/doc/images/team.png deleted file mode 100644 index e9a8400bd..000000000 Binary files a/doc/images/team.png and /dev/null differ diff --git a/doc/images/team_member.png b/doc/images/team_member.png deleted file mode 100644 index 6a6babb95..000000000 Binary files a/doc/images/team_member.png and /dev/null differ diff --git a/doc/images/user_token.png b/doc/images/user_token.png deleted file mode 100644 index 3558b2d55..000000000 Binary files a/doc/images/user_token.png and /dev/null differ diff --git a/scripts/base/install_bin.sh b/scripts/base/install_bin.sh index c04ae6a01..e0076b213 100755 --- a/scripts/base/install_bin.sh +++ b/scripts/base/install_bin.sh @@ -8,8 +8,8 @@ source $TCA_SCRIPT_ROOT/utils.sh # 代码库根目录 TCA_ROOT=$( cd "$(dirname $TCA_SCRIPT_ROOT)"; pwd ) -LIB_GITHUB_URL=${LIB_GITHUB_URL:-"https://github.com/TCATools/tca_lib/releases/download/v20240716.1/tca_lib-v1.4.zip"} -LIB_GONGFENG_URL=${LIB_GONGFENG_URL:-"https://git.code.tencent.com/TCA/tca-tools/tca_lib.git"} +LIB_GITHUB_URL=${LIB_GITHUB_URL:-"https://github.com/TCATools/tca_lib/releases/download/v20240716.3/tca_lib-v1.5.zip"} +LIB_GONGFENG_URL=${LIB_GONGFENG_URL:-"https://git.code.tencent.com/TCA/tca-tools/tca_lib.git#v20240716.3"} LIB_DIR_NAME="tca_lib" @@ -38,7 +38,8 @@ function downloader() { # 使用工蜂默认密码 user=$2 password=$3 - git clone ${url:0:8}${user}:${password}@${url:8} + # ${url: -11} 中间要有空格,才能是截取后几位 + git clone -b ${url: -11} ${url:0:8}${user}:${password}@${url:8:-12} cmd_ret=$? if [[ ${cmd_ret} == 0 ]] ; then rm -rf "${TCA_ROOT}/${LIB_DIR_NAME}/.git" @@ -79,11 +80,21 @@ function deepmove() { # 遍历 for target in $(find $src_dir -type f); do relpath=$(realpath "$target" --relative-to=$src_dir) - # 先判断md5值,有变化才复制覆盖 - isSame $target $dst_dir/$relpath - ret=$? + if [ ! -e "$dst_dir/$relpath" ]; then + # 目标位置不存在 + ret=1 + else + # 先判断md5值,有变化才复制覆盖 + isSame $target $dst_dir/$relpath + ret=$? + fi if [[ $ret == 1 ]]; then LOG_INFO "update lib: $relpath" + # 判断目标位置的目录是否存在 + parent_dir=$(dirname "$dst_dir/$relpath") + if [ ! -d "$parent_dir" ]; then + mkdir -p "${parent_dir}" + fi cp $target $dst_dir/$relpath fi done