- Clone your repository
$ git clone <bitbucket-repo-url>
- Add the remote origin for openshift
Your local clone has then your other repo (bitbucket etc.) as remote repo. Your remote repo is stored with the alias "origin" (the default alias used by git if you clone). You then add the openshift repo as remote to your clone. You do that while explicitly using an alias for the remote repo you add - I'm using "openshift" as alias here:
$ git remote add openshift -f <openshift-git-repo-url>
- Merge your openshift repo with your local bitbucket clone
$ git merge openshift/master -s recursive -X ours
With this command you tell git to merge the master branch in the openshift git repo with your local git repo. You tell it to merge using the recursive merging strategy and to choose your ("ours") version when there are conflicts.
- Finaly push your git repo to openshift
$ git push openshift HEAD