1

I download code from a branch github by pressing download zip button then I unzip the file and make some change. Is there anyway i can push that code to the same repo as a new branch?

  • If you have permissions sure u can. – D A May 17 '22 at 09:07
  • https://stackoverflow.com/search?q=%5Bgithub%5D+downloaded+zip , https://stackoverflow.com/search?q=%5Bgit%5D+clone+into+non-empty+directory – phd May 17 '22 at 12:22

1 Answers1

1

Create new branch: git checkout -b <name of branch>

Go to new branch: git checkout <name of branch>

Check status of files: git status

Add any files that have been changed: git add <files>

Commit files: git commit -m "<commit message>"

Push to GitHub: git push -u origin <name of branch>

Joshua Zeltser
  • 488
  • 2
  • 9