From bde4eca37ba195f25705a427e669adea20c84418 Mon Sep 17 00:00:00 2001 From: jichuan Date: Tue, 18 Jul 2023 17:35:19 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=8F=96=E6=B6=88=E5=9C=A8=E7=BC=96?= =?UTF-8?q?=E8=AF=91=E5=99=A8=E6=89=A7=E8=A1=8Cnpm=20install,=20=E6=94=BE?= =?UTF-8?q?=E5=9C=A8=E9=A2=84=E5=A4=84=E7=90=86=E4=B8=AD=E6=89=A7=E8=A1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: jichuan --- ide/build.py | 22 ---------------------- ide/build.sh | 1 - patches/build.patch | 30 ++++++++++++++++++++++++++++++ patches/patches.json | 5 +++++ 4 files changed, 35 insertions(+), 23 deletions(-) delete mode 100755 ide/build.py create mode 100644 patches/build.patch diff --git a/ide/build.py b/ide/build.py deleted file mode 100755 index 0a7ec14a..00000000 --- a/ide/build.py +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env python3 -# -*- coding: utf-8 -*- -# Copyright (C) 2023 Huawei Device Co., Ltd. -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import subprocess -import sys - -print("1 =", sys.argv[1]) -print("build.py start!") -subprocess.run(["npm", "install"]) -subprocess.run(["npm", "run", "compile"]) \ No newline at end of file diff --git a/ide/build.sh b/ide/build.sh index f03cb923..c406eaeb 100755 --- a/ide/build.sh +++ b/ide/build.sh @@ -18,7 +18,6 @@ echo "1=$1" echo "2=$2" SOURCE="${BASH_SOURCE[0]}" cd $(dirname ${SOURCE}) -npm install npm run compile ohos mv $1/dist $2/dist mkdir -p $2/dist/bin diff --git a/patches/build.patch b/patches/build.patch new file mode 100644 index 00000000..f68d3557 --- /dev/null +++ b/patches/build.patch @@ -0,0 +1,30 @@ +From c2dea6cad4b87cb951d362d019d829d86b9fdd08 Mon Sep 17 00:00:00 2001 +From: jichuan +Date: Tue, 18 Jul 2023 17:27:00 +0800 +Subject: [PATCH] =?UTF-8?q?=E4=BB=93=E5=BA=93developtools=5Fsmartperf=5Fho?= + =?UTF-8?q?st=E9=9C=80=E8=A6=81npm=20install,=20=E9=85=8D=E7=BD=AE?= + =?UTF-8?q?=E5=9C=A8=E9=A2=84=E5=A4=84=E7=90=86=E8=BF=87=E7=A8=8B=E4=B8=AD?= +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Signed-off-by: jichuan +--- + prebuilts_download_config.json | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/prebuilts_download_config.json b/prebuilts_download_config.json +index 44740a9..4348348 100644 +--- a/prebuilts_download_config.json ++++ b/prebuilts_download_config.json +@@ -3,6 +3,7 @@ + "npm_install_path": [ + "developtools/ace_ets2bundle/compiler", + "developtools/ace_js2bundle/ace-loader", ++ "developtools/smartperf_host/ide", + "third_party/jsframework", + "third_party/parse5/packages/parse5", + "arkcompiler/ets_frontend/legacy_bin/api8", +-- +2.34.1 + diff --git a/patches/patches.json b/patches/patches.json index 65982b06..87aab072 100644 --- a/patches/patches.json +++ b/patches/patches.json @@ -4,6 +4,11 @@ "project": "productdefine_common", "patch_file": "productdefine_common.patch", "path": "productdefine/common" + }, + { + "project": "build", + "patch_file": "build.patch", + "path": "build" } ] } \ No newline at end of file -- Gitee