ref: 打包脚本调整
This commit is contained in:
15
README.md
15
README.md
@@ -4,25 +4,18 @@
|
|||||||
|
|
||||||
OS: Ubuntu 18.04 / 22.04 (Recommendation)
|
OS: Ubuntu 18.04 / 22.04 (Recommendation)
|
||||||
|
|
||||||
Arch: amd64
|
Golang: go1.22.5 (or above)
|
||||||
|
|
||||||
Golang: go1.22.1 linux/amd64
|
|
||||||
|
|
||||||
Database: 10.6.16-MariaDB, Redis server v=5.0.5 (or above)
|
Database: 10.6.16-MariaDB, Redis server v=5.0.5 (or above)
|
||||||
|
|
||||||
node.js: v18.16.0 (or above)
|
node.js: v20.18.0 (or above)
|
||||||
|
|
||||||
## Build Guide
|
## Build Guide
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://xxx@bitbucket.org/bluearcuscom/ems.git omc.git
|
git clone https://xxx@git/ems.git omc.git
|
||||||
cd omc.git
|
cd omc.git
|
||||||
git pull
|
bash pkg.sh --web --api -v 2.2503.2
|
||||||
cd fe.ems.vue3
|
|
||||||
npm install
|
|
||||||
npm run build
|
|
||||||
cd ../build.ems
|
|
||||||
./build.sh deb
|
|
||||||
|
|
||||||
find "${fehooksdir}" -type f -name '*.ts' -exec sed -i 's/[一-龥()“”,。?!]~·]//g' {} +
|
find "${fehooksdir}" -type f -name '*.ts' -exec sed -i 's/[一-龥()“”,。?!]~·]//g' {} +
|
||||||
|
|
||||||
|
|||||||
6
pkg.sh
6
pkg.sh
@@ -46,7 +46,7 @@ if [ -n "$BuildWeb" ]; then
|
|||||||
npm install --registry https://registry.npmmirror.com
|
npm install --registry https://registry.npmmirror.com
|
||||||
npm run build
|
npm run build
|
||||||
|
|
||||||
output=$BuildDir/build/linux/usr/local/etc/omc/web
|
output=$BuildDir/linux/usr/local/etc/omc/web
|
||||||
rm -rf $output
|
rm -rf $output
|
||||||
cp -rf dist/default/config.js dist/config.js
|
cp -rf dist/default/config.js dist/config.js
|
||||||
cp -rf dist $output
|
cp -rf dist $output
|
||||||
@@ -66,7 +66,7 @@ if [ -n "$BuildApi" ]; then
|
|||||||
MOD_CONFIG="be.ems/src/framework/config"
|
MOD_CONFIG="be.ems/src/framework/config"
|
||||||
go build -o omc -v -ldflags "-s -w -X '$MOD_CONFIG.Version=$VERSION' -X '$MOD_CONFIG.BuildTime=$(date)' -X '$MOD_CONFIG.GoVer=$(go version)'"
|
go build -o omc -v -ldflags "-s -w -X '$MOD_CONFIG.Version=$VERSION' -X '$MOD_CONFIG.BuildTime=$(date)' -X '$MOD_CONFIG.GoVer=$(go version)'"
|
||||||
|
|
||||||
output=$BuildDir/build/linux/usr/local/bin
|
output=$BuildDir/linux/usr/local/bin
|
||||||
cp -rf omc $output/omc
|
cp -rf omc $output/omc
|
||||||
echo "===> go build omc copy to $output"
|
echo "===> go build omc copy to $output"
|
||||||
|
|
||||||
@@ -79,6 +79,6 @@ fi
|
|||||||
|
|
||||||
# =================== deb/rpm
|
# =================== deb/rpm
|
||||||
echo
|
echo
|
||||||
bash $BuildDir/build/build.sh -v $VERSION
|
bash $BuildDir/build.sh -v $VERSION
|
||||||
|
|
||||||
# bash pkg.sh --web --api -v 2.2503.2
|
# bash pkg.sh --web --api -v 2.2503.2
|
||||||
|
|||||||
Reference in New Issue
Block a user