git - How does initializing a repository with a README help in letting you immediately clone the repository to your computer? -
how connected in way?
git can clone empty repository.
but in case, end-up repo no branch, can unsettling git beginners.
that means that, when create own commit in empty cloned repo, need setup upstream branch on first push, git push -u origin master
.
again, bit of hassle when discover git.
see "why need explicitly push new branch?"
hence recommendation creating @ least 1 file, meaning @ least 1 commit in master
branch.
plus, cloned repo has local master
branch upstream branch already setup: when new commits done locally, simple git push
enough send them github repo.
those 2 points (local repo master
branch, and remote tracking branch origin/master
) make easier experience.
if importing existing repo, on other hand, want empty repo begin with.
Comments
Post a Comment