Git branch another branch from current branch

Your current branch is master and if u create another branch like that git branch develop,then in branch develop you will have similar code about master。how can i get an empty branch.

  • GIt - how to create and switch to a branch when I already modify the code?
  • Cant git push to master after revert
  • Undoing a 'git push'
  • Github need login in console only for one repo
  • How to reconnect to my git repository on GitLab from NetBeans IDE 8 and Jenkins?
  • Is there a way to confine Git to a sparse checkout?
  • How to work on multiple projects simultaneously using Git?
  • replay git commits on repo with different root
  • Git: folder with same name as root ignored
  • permission denied (public key) error for ssh -vT
  • Does a svn frontend for git exist
  • Succinctly specify exact state of git repository
  • One Solution collect form web for “Git branch another branch from current branch”

    You can create an orphan branch, which start without parent, and will be effectively “empty”.

    git checkout --orphan develop

    This is since git 1.7.2: see “In git, is there a simple way of introducing an unrelated branch to a repository?”.

    Git Baby is a git and github fan, let's start git clone.