Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Copy a Bitbucket Repository from one account to another bitbucket account

Tags:

my friend have a repository on Bitbucket and I want to copy that repository (for future reference so that if he delete that repository i would still have one copy) to my bitbucket account. I tried bare-cloning,mirror push and etc... but :(

may be I'm missing some set of commands

PS: repository type is git (not hg)

like image 694
erickhushwaha Avatar asked Dec 03 '13 05:12

erickhushwaha


People also ask

How do I move a repository from one organization to another?

On GitHub.com, navigate to the main page of the repository. Under your repository name, click Settings. Under "Danger Zone", click Transfer. Read the information about transferring a repository, then type the name of the user or organization you'd like to transfer ownership of the repository to.

How do I clone a repository in Bitbucket?

Clone a Bitbucket repositoryClick + in the global sidebar on the left, and under Get to work select Clone this repository. Select HTTPS from the menu in the upper-right (unless you've already set up your SSH keys). Copy the clone command.

How do I clone a Bitbucket repository with username and password?

The first time you clone a repository you are prompted to provide your Bitbucket username and password. Provide your account name as the username, and type the Bitbucket App password into the password field. After the authentication completes, the git clone operation proceeds.

How do I copy a repository to another?

Navigate to the repository you just cloned. Pull in the repository's Git Large File Storage objects. Mirror-push to the new repository. Push the repository's Git Large File Storage objects to your mirror.


1 Answers

Recently, I had to do this for multiple repositories. I found a better way than cloning the repo locally and pushing it to another remote(on Bitbucket).

Bitbucket provides import repository feature. It can be found under Repositories > Import Repository

Bitbucket - Import Repo

Just provide https url of the repo and access credentials, and bitbucket will do the rest for you.

I know this is an old question but this method is easier and saves a lot of time. Hope this helps others in future.

like image 56
Nitish Parkar Avatar answered Oct 02 '22 21:10

Nitish Parkar