mirror of
https://github.com/espressif/openthread.git
synced 2026-10-21 06:58:21 +00:00
[continuous-integration] remove git clean in scripts (#4988)
This removes the use of `git clean` in scripts to prevent accidental loss of work.
This commit is contained in:
@@ -29,6 +29,9 @@
|
||||
|
||||
set -euxo pipefail
|
||||
|
||||
readonly OT_SRCDIR="$(pwd)"
|
||||
readonly OT_BUILDDIR="$OT_SRCDIR/build"
|
||||
|
||||
readonly OT_COMMON_OPTIONS=(
|
||||
"-DOT_COMPILE_WARNING_AS_ERROR=on"
|
||||
"-DOT_PLATFORM=simulation"
|
||||
@@ -36,8 +39,7 @@ readonly OT_COMMON_OPTIONS=(
|
||||
|
||||
reset_source()
|
||||
{
|
||||
git checkout -- .
|
||||
git clean -xfd
|
||||
rm -rf "$OT_BUILDDIR"
|
||||
}
|
||||
|
||||
build_all_features()
|
||||
@@ -71,21 +73,20 @@ build_all_features()
|
||||
|
||||
reset_source
|
||||
|
||||
git checkout -- .
|
||||
git clean -xfd
|
||||
mkdir build && cd build
|
||||
mkdir -p "$OT_BUILDDIR"
|
||||
cd "$OT_BUILDDIR"
|
||||
cmake -GNinja "${options[@]}" ..
|
||||
ninja
|
||||
cd ..
|
||||
cd "$OT_SRCDIR"
|
||||
}
|
||||
|
||||
build_toranj()
|
||||
{
|
||||
reset_source
|
||||
./tests/toranj/build.sh cmake
|
||||
top_builddir="$OT_BUILDDIR" ./tests/toranj/build.sh cmake
|
||||
|
||||
reset_source
|
||||
./tests/toranj/build.sh cmake-posix
|
||||
top_builddir="$OT_BUILDDIR" ./tests/toranj/build.sh cmake-posix
|
||||
}
|
||||
|
||||
main()
|
||||
|
||||
Reference in New Issue
Block a user