diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7907ce13c273ac8b130ad12b35df9f5e4a9a7cd2..7f3734c2c92d8ff3564414bbae12a049f2a1a8eb 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -10,7 +10,7 @@ stages: check:prebuilt: stage: ci script: - - git log -1 --oneline | grep "test=develop" || exit -1 + - ./paddle/fluid/lite/tools/build.sh check_need_ci - ./paddle/fluid/lite/tools/build.sh check_style build:server: diff --git a/paddle/fluid/lite/tools/build.sh b/paddle/fluid/lite/tools/build.sh index 8b3a742d5eda708fd406714b97f116c4e334ecfa..53d4638e465622452dd7a934a62fa98f161d58e2 100755 --- a/paddle/fluid/lite/tools/build.sh +++ b/paddle/fluid/lite/tools/build.sh @@ -13,6 +13,11 @@ function prepare_for_codegen { mkdir -p ./paddle/fluid/lite/gen_code touch ./paddle/fluid/lite/gen_code/__generated_code__.cc } + +function check_need_ci { + git log -1 --oneline | grep "test=develop" || exit -1 +} + function cmake_x86 { prepare_for_codegen cmake .. -DWITH_GPU=OFF -DWITH_MKLDNN=OFF -DLITE_WITH_X86=ON ${common_flags} @@ -232,6 +237,10 @@ function main { check_style shift ;; + check_need_ci) + check_need_ci + shift + ;; *) # unknown option print_usage