osmo-clean-workspace: fix force checkout of a subdirectory

Instead of the subdirectory, the main repository was
forced checked out.

Change-Id: If23e89872edf48dc5b751b3c069faf585bd6a3ef
This commit is contained in:
Alexander Couzens 2018-02-27 15:54:29 +01:00
parent 8bab2702b4
commit a45a34e9d0
1 changed files with 2 additions and 2 deletions

View File

@ -31,12 +31,12 @@ git clean -dxf -e "$deps" -e "layer1-headers"
# but clean each git of build artifacts.
if [ -d "$deps" ]; then
for dep_dir in "$deps"/* ; do
git checkout -f HEAD
git -C "$dep_dir" checkout -f HEAD
git -C "$dep_dir" clean -dxf
done
fi
if [ -d "layer1-headers" ]; then
git checkout -f HEAD
git -C "layer1-headers" checkout -f HEAD
git -C "layer1-headers" clean -dxf
fi