Commit 9b517c53 authored by qq_38816927's avatar qq_38816927

清除

parent 277f7dff
@echo off
setlocal
cd /d "%~dp0"
rem 与 :composeApp:cleanHarmonyAppEntryBuildsAndNativeLibs 相同:存在则整目录删除
if exist "harmonyApp\entry\build" rmdir /s /q "harmonyApp\entry\build"
if exist "harmonyApp\entry\libs\arm64-v8a" rmdir /s /q "harmonyApp\entry\libs\arm64-v8a"
if exist "harmonyApp\entry\libs\x86_64" rmdir /s /q "harmonyApp\entry\libs\x86_64"
if exist "harmonyApp\entry\src\main\cpp\include" rmdir /s /q "harmonyApp\entry\src\main\cpp\include"
endlocal
......@@ -205,7 +205,7 @@ tasks.register("cleanHarmonyAppEntryBuildsAndNativeLibs") {
// 为不同类型(debug、release)OHOS构建注册Copy任务并发布到Harmony App目录
arrayOf("debug", "release").forEach { type ->
tasks.register<Copy>("publish${type.capitalizeUS()}BinariesToHarmonyApp") {
dependsOn("cleanHarmonyAppEntryBuildsAndNativeLibs")
//dependsOn("cleanHarmonyAppEntryBuildsAndNativeLibs")
group = "harmony" // 归类到harmony任务组
dependsOn("link${type.capitalizeUS()}SharedOhosArm64", "link${type.capitalizeUS()}SharedOhosX64")
duplicatesStrategy = DuplicatesStrategy.INCLUDE
......
......@@ -50,6 +50,10 @@ goto parse
if "!PLATFORM!"=="" set "PLATFORM=%DEFAULT_PLATFORM%"
if "!TARGET_ID!"=="" set "TARGET_ID=%DEFAULT_TARGET_ID%"
REM 与 :composeApp:cleanHarmonyAppEntryBuildsAndNativeLibs 一致,清理 harmonyApp/entry 中间目录(脚本在仓库根目录)
call "%~dp0..\cleanHarmonyAppEntryBuildsAndNativeLibs.bat"
if errorlevel 1 exit /b %errorlevel%
REM Record script start time (epoch seconds for elapsed calculation)
for /f %%t in ('powershell -NoProfile -Command "[int][double]::Parse((Get-Date -UFormat '%%s'))"') do set START_TIME=%%t
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment