feat: [CDE-182]: Fixing clone check. (#2259)

* feat: [CDE-182]: Fixing clone check.
This commit is contained in:
Dhruv Dhruv 2024-07-22 11:24:33 +00:00 committed by Harness
parent d159df6b7b
commit bed2659e03

View File

@ -19,8 +19,8 @@ if ! command -v git >/dev/null 2>&1; then
exit 1
fi
# Clone the repository only if it doesn't exist
if [ ! -d "$repo_name" ]; then
# Clone the repository inside the working directory if it doesn't exist
if [ ! -d ".git" ]; then
echo "Cloning the repository..."
git clone "$repo_url" --branch "$branch" .
else