Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

Adding a local repository to Bitbucket using Git

//cd into your dir that have your code
//initiate it as a git repo
git init
git add --all
git commit -m "Initial Commit"
//copy the url for your EMPTY repo in bitbucket
//set the remote url for your repo and push your initial commit
git remote add origin https://<Bitbucket_Username>:<App_Password>@bitbucket.org/<Repo_Name>.git
git push -u origin master
Comment

repo from bitbucket to github

cd $HOME/Code/repo-directory
# Rename Origin to bitbucket
git remote rename origin bitbucket
# Add the origin of your new github repository
git remote add origin https://github.com/<username>/<repo-name>.git
# Push ypur branch master to your github repo
git push origin master
# Remove the old origin
git remote rm bitbucket
Comment

how to fork from github to bitbucket

$ git clone https://github.com/cakephp/cakephp
$ cd cakephp
$ git push git@bitbucket.org:mg/cakephp.git master
Comment

move repository from Bitbucket to GitHub

1. git clone https://USER@bitbucket.org/USER/PROJECT.git
2. cd PROJECT
3. git remote add upstream https://github.com:USER/PROJECT.git
4. git push upstream <branchName>
Comment

PREVIOUS NEXT
Code Example
Shell :: how to make top bar transparent ubuntu 
Shell :: setup git on windows 
Shell :: create ssh key 
Shell :: mkdir creating multiple containing folders 
Shell :: bash get absolute path 
Shell :: git set-url no such remote origin 
Shell :: how to kickstart ARD on mac using terminal 
Shell :: vim cut paste 
Shell :: linux how to write to file 
Shell :: merge when pipeline succeeds gitlab 
Shell :: git tag 
Shell :: Brave on OpenSUSE 
Shell :: update composer 
Shell :: install git linux 
Shell :: online c linux compiler 
Shell :: libssl-dev ubuntu get version 
Shell :: append two image terminal 
Shell :: docker swarm get nodes 
Shell :: git untag 
Shell :: android ndk - configure does not recognize androideabi 
Shell :: for while bash 
Shell :: Install JDK on Rocky Linux 8 
Shell :: linux make executable 
Shell :: Export SSH Auth Key 
Shell :: how to install .whl file in windows 10 
Shell :: preserve permissions tar 
Shell :: Does Ubuntu use deb or rpm? 
Shell :: gvm not generated password 
Shell :: ubuntu chang host name 
Shell :: torshammer github 
ADD CONTENT
Topic
Content
Source link
Name
6+6 =