This commit is contained in:
Vivek Teega 2023-12-18 19:21:33 +05:30
parent d00cd300b3
commit 35f3e694c6

View File

@ -21,12 +21,13 @@ jobs:
fi
if [ -d "/home/production/deployed/dappbundle/${{ github.event.repository.name }}" ]; then
echo "Repository exists. Skipping Git clone."
else
echo "Repo does not exist. Cloning repository..."
cd /home/production/deployed/dappbundle && git clone "https://github.com/ranchimall/${{ github.event.repository.name }}.git"
echo "Repository exists. Remove folder "
rm -r "/home/production/deployed/dappbundle/${{ github.event.repository.name }}"
fi
echo "Cloning repository..."
cd /home/production/deployed/dappbundle && git clone "https://github.com/ranchimall/${{ github.event.repository.name }}.git"
cd "/home/production/deployed/dappbundle/${{ github.event.repository.name }}" && rm -r .gitattributes
cd /home/production/deployed/dappbundle/ && git push "https://ranchimalldev:${{ secrets.RM_ACCESS_TOKEN }}@github.com/ranchimall/dappbundle.git"