diff --git a/src/Drupal/Modules/site_hosting/src/Plugin/Command/GitCheckout.php b/src/Drupal/Modules/site_hosting/src/Plugin/Command/GitCheckout.php index 7e0760594..a3fa3c33d 100644 --- a/src/Drupal/Modules/site_hosting/src/Plugin/Command/GitCheckout.php +++ b/src/Drupal/Modules/site_hosting/src/Plugin/Command/GitCheckout.php @@ -14,10 +14,8 @@ * label = @Translation("Git Checkout"), * description = @Translation("Clone a git repository and checkout the desired git reference."), * command = { - * "git clone [git_remote] [git_root]", - * "cd [git_root]", - * "git fetch", - * "git checkout [git_reference]", + * "git clone [git_remote] [git_root] || echo 'Clone already exists.'", + * "cd [git_root] && git fetch && git checkout [git_reference]", * } * ) */