Git Commands git clone, delete branch and delete repository

How to clone using git

Using git clone you can make a copy of repo or clone it in a new directory in your local system. Using git clone you can located the original repository on the local system

git clone <URL>
git clone

How to cut or create new branch

git branch -b branchname

How to delete a Git branch locally and remotely


git branch -d <branch_name>
git branch -d branchname


git push origin --delete <branch_name>
git push origin --delete branchname

How to delete a Git repository locally and remotely


remove .git folder or run rm .git command


  1. First login in git hub
  2. Select the repository which you want to delete

3 Select “Setting” tab on top

4 Go down and select “Delete this repository”

5. Enter confirmation text in textbox and click on below button

6 Done, got success message

Leave a Reply

Your email address will not be published. Required fields are marked *