scripts: dev_cli: Simplify the build command exit path

Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
Samuel Ortiz 2020-02-07 22:14:19 +01:00 committed by Sebastien Boeuf
parent 0a1d6e1cb3
commit c706ca1522

View File

@ -191,16 +191,7 @@ cmd_build() {
"$CTR_IMAGE" \
cargo build \
--target-dir "$CTR_CLH_CARGO_TARGET" \
"${cargo_args[@]}"
ret=$?
# If `cargo build` was successful, let's copy the binaries to a more
# accessible location.
[ $ret -eq 0 ] && {
cargo_bin_dir="$CLH_CARGO_TARGET/$build"
say "Binaries placed under $cargo_bin_dir"
}
"${cargo_args[@]}" && say "Binaries placed under $CLH_CARGO_TARGET/$build"
}
cmd_clean() {