From 691bb89829e2483ff2f83e2bb3ff249e96f72735 Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Wed, 19 Mar 2025 20:08:16 +0800 Subject: [PATCH] =?UTF-8?q?ref:=20=E6=9E=84=E5=BB=BA=E5=B7=A5=E5=85=B7?= =?UTF-8?q?=E9=87=8D=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.sh | 19 ++++++++----------- build_after.sh | 11 ----------- build_before.sh | 20 -------------------- 3 files changed, 8 insertions(+), 42 deletions(-) delete mode 100644 build_after.sh delete mode 100644 build_before.sh diff --git a/build.sh b/build.sh index c83ef21..6d2a72a 100755 --- a/build.sh +++ b/build.sh @@ -100,9 +100,10 @@ app() { # 数据库脚本 common属于重建脚本 modeList="standard lite" for v in ${modeList}; do - cp -rf $BuildDir/usr/local/etc/omc/database/${v}/common/* $BuildDir/usr/local/etc/omc/database/${v}/install/ - cp -rf $BuildDir/usr/local/etc/omc/database/${v}/common/* $BuildDir/usr/local/etc/omc/database/${v}/upgrade/ - rm -rf $BuildDir/usr/local/etc/omc/database/${v}/common + path=$BuildDir/usr/local/etc/omc/database/${v} + cp -rf $path/common/* $path/install/ + cp -rf $path/common/* $path/upgrade/ + rm -rf $path/common done } @@ -156,21 +157,17 @@ cp -rf ${BuildPackagelDir}/${PACKAGE_MANAGER}/* ${BuildDir} if [[ $PACKAGE_MANAGER = "deb" ]]; then cp -rf ${BuildLinuxDir}/* ${BuildDir} cd ${BuildDir} - # 打包前处理 - . ./build_before.sh + # 应用文件处理 + app # 打包 deb - # 打包后处理 - . ./build_after.sh elif [[ $PACKAGE_MANAGER = "rpm" ]]; then cp -rf ${BuildLinuxDir}/* ${BuildDir}/BUILD cd ${BuildDir}/BUILD - # 打包前处理 - . $RootDir/build_before.sh + # 应用文件处理 + app # 打包 rpm - # 打包后处理 - . $RootDir/build_after.sh else echo "unknown runing: $PACKAGE_MANAGER" exit 1 diff --git a/build_after.sh b/build_after.sh deleted file mode 100644 index b38cbfe..0000000 --- a/build_after.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash -echo -echo "==> after compilation" -# 编译目录 -echo "BuildDir: $BuildDir" -# 发布包目录 -echo "ReleaseDir: $ReleaseDir" -# 发布包文件名称 -echo "ReleaseFileName: $ReleaseFileName" - -# =================== diff --git a/build_before.sh b/build_before.sh deleted file mode 100644 index 2e47540..0000000 --- a/build_before.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash -echo -echo "==> before compilation" -# 编译目录 -echo "BuildDir: $BuildDir" -# 发布包目录 -echo "ReleaseDir: $ReleaseDir" -# 发布包文件名称 -echo "ReleaseFileName: $ReleaseFileName" - -# =================== - -# 数据库脚本 common属于重建脚本 -modeList="standard lite" -for v in ${modeList}; do - path=$BuildDir/usr/local/etc/omc/database/${v} - cp -rf $path/common/* $path/install/ - cp -rf $path/common/* $path/upgrade/ - rm -rf $path/common -done