How to check out a branch at Bitbucket

I have a Git repository at https: // user_name@bitbucket.org /path/git.git . This repository has a branch with the name feature/myFeatureI want to check. I launched

git init

to the desired folder, and then, according to Bitbucket, I need to run

git fetch && git checkout feature/myFeature

However, I get the following error:

fatal: remote repository not specified. Please provide the URL or remote name from which you should change to be extracted.

I think I need to specify a repository, but I don’t know how to do this, and at the same time specify a branch.

What should I do?

+4
source share
1 answer

(git init ):

git remote add origin https://user_name@bitbucket.org/path/git.git

+7

All Articles